/* Reset e stili base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    background-color: #ffffff;
    color: #333;
    min-height: 100vh;
    overflow-x: hidden;
}

/* Container principale */
.app-container {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

/* Controllo musica */
.music-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.music-toggle:hover {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 1);
}

/* Icona dell'audio */
.icon-music {
    position: relative;
    width: 16px;
    height: 16px;
    display: block;
}

.icon-music::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 8px;
    height: 8px;
    background: #333;
    transform: translateY(-50%);
    clip-path: polygon(0 30%, 45% 30%, 45% 0, 100% 0, 100% 100%, 45% 100%, 45% 70%, 0 70%);
}

.icon-music::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 8px;
    height: 8px;
    transform: translateY(-50%);
    border-right: 2px solid #333;
    border-radius: 0 8px 8px 0;
}

/* Stato mutato */
.music-toggle.muted .icon-music::after {
    display: none;
}

.music-toggle.muted .icon-music::before {
    opacity: 0.5;
}

/* Linea diagonale per lo stato mutato */
.music-toggle.muted::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background: #333;
    transform: rotate(-45deg);
    opacity: 0.7;
}

/* Contenitore domande */
.questions-container {
    max-width: 600px;
    width: 100%;
    text-align: center;
}

.question {
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
}

.question.current {
    opacity: 1;
    transform: translateY(0);
}

.question.fade-out {
    opacity: 0;
    transform: translateY(-20px);
}

.question h1, .question h2 {
    font-size: 2.5em;
    margin-bottom: 30px;
    font-weight: 300;
}

/* Input e bottoni */
.response-input {
    width: 100%;
    max-width: 400px;
    padding: 15px;
    font-size: 1.2em;
    border: none;
    border-bottom: 2px solid #ddd;
    margin-bottom: 20px;
    background: transparent;
    transition: all 0.3s ease;
}

.response-input:focus {
    outline: none;
    border-bottom-color: #333;
}

.btn-start, .btn-continue {
    padding: 12px 30px;
    font-size: 1.1em;
    background: #333;
    color: #fff;
    border: none;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-start:hover, .btn-continue:hover {
    background: #555;
    transform: translateY(-2px);
}

/* Contenitore emozioni */
.emotions-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.emotion-card {
    background: #fff;
    border-radius: 15px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    align-items: center;
    min-height: 150px; /* Altezza minima fissa */
    justify-content: center;
}

.emotion-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.emotion-icon {
    width: 50px;
    height: 50px;
    object-fit: contain;
    margin-bottom: 10px;
}

/* Stili per il nome dell'emozione */
.emotion-name {
    font-size: 1.1em;
    margin: 0;
    color: #333;
    /* Gestione del testo lungo */
    word-wrap: break-word;
    overflow-wrap: break-word;
    hyphens: auto;
    max-width: 100%;
    padding: 0 5px;
    line-height: 1.3;
    /* Limita a 2 righe di testo */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Animazioni */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.5s ease forwards;
}

.hidden {
    display: none;
}

/* Stili per la griglia delle emozioni */
.emotions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 20px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.emotions-grid.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Effetto hover e selezione delle emozioni */
.emotion-select-card {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    border: 2px solid transparent;
}

.emotion-select-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.emotion-select-card.selected {
    border-color: #333;
    background-color: #f8f8f8;
    transform: scale(1.05);
}

.emotion-select-card img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 30px;
    margin-bottom: 12px;
}

.emotion-select-card h4 {
    font-size: 1.1em;
    margin: 0;
    color: #333;
}

.error-container {
    text-align: center;
    padding: 20px;
    background: #fff5f5;
    border-radius: 8px;
    margin: 20px 0;
}

.error-message {
    color: #e74c3c;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.btn-retry {
    background: #3498db;
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 1em;
}

.btn-retry:hover {
    background: #2980b9;
    transform: translateY(-2px);
}

/* Loader per la transizione */
.loader-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    justify-content: center;
    align-items: center;
    opacity: 0;
    visibility: hidden;
    transition: all 0.5s ease;
    z-index: 1000;
}

.loader-overlay.visible {
    opacity: 1;
    visibility: visible;
}

.loader {
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #333;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Stili per la sezione storia */
.story-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #fff;
    opacity: 0;
    transition: opacity 0.8s ease;
}

.story-container.visible {
    opacity: 1;
}

/* Contenitore dell'opera d'arte */
.artwork-container {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
    transition: all 1.5s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f0f0f0; /* Colore di sfondo di fallback */
}

.artwork-container.fullscreen {
    width: 100%;
    height: 100%;
}

.artwork-container.reduced {
    width: 100%;
    height: 100%;
}

.artwork-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transform: scale(1.2);
    transition: transform 8s ease;
    display: block;
}

/* Aggiungi debug visivo per l'immagine */
.artwork-image:not([src]), 
.artwork-image[src=""], 
.artwork-image[src="#"] {
    background: #ddd;
    position: relative;
}

.artwork-image:not([src])::after, 
.artwork-image[src=""]::after, 
.artwork-image[src="#"]::after {
    content: 'Immagine non disponibile';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #666;
}

/* Modifica l'effetto zoom */
.artwork-image.zoom-out {
    transform: scale(1);
}

/* Overlay per chiudere il pannello */
.story-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 20vh; /* Altezza della parte cliccabile */
    background: transparent;
    z-index: 1000;
    display: none;
    cursor: pointer;
}

.story-overlay.visible {
    display: block;
}

/* Pannello delle informazioni */
.story-info-panel {
    position: fixed;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 80vh;  /* Mantiene spazio in alto */
    background: rgba(255, 255, 255, 0.95);
    padding: 40px;
    opacity: 0;
    transform: translateY(100%);
    transition: all 0.8s cubic-bezier(0.4, 0, 0.2, 1);
    overflow-y: auto;
    z-index: 1001;
    visibility: hidden;
    border-radius: 20px 20px 0 0;
}

.story-info-panel.visible {
    opacity: 1;
    transform: translateY(0);
    visibility: visible;
}

.story-info-panel.closing {
    transform: translateY(100%);
    opacity: 0;
}

.story-info-panel .artist-section {
    display: flex;
    align-items: center;
    gap: 15px;
    padding-bottom: 20px;
    border-bottom: 1px solid rgba(0,0,0,0.1);
}

.story-info-panel .artist-section img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
}

.story-info-panel .artist-name {
    margin: 0;
    font-size: 1.2em;
    color: #333;
    cursor: pointer;
    transition: color 0.3s ease;
}

.story-info-panel .artist-name:hover {
    color: #666;
}

.story-info-panel .story-narration {
    padding: 20px 0;
}

.story-info-panel .story-narration h2 {
    margin: 0 0 15px 0;
    font-size: 1.4em;
    color: #333;
}

.story-info-panel .story-narration p {
    margin: 0;
    line-height: 1.6;
    color: #666;
}

.story-info-panel .artwork-gallery {
    margin-top: auto;
    padding-top: 20px;
}

.story-info-panel .artwork-link {
    display: inline-block;
    padding: 12px 24px;
    background: #333;
    color: #fff;
    text-decoration: none;
    border-radius: 25px;
    transition: background 0.3s ease;
}

.story-info-panel .artwork-link:hover {
    background: #444;
}

/* Sezione artista */
.artist-section {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    transition-delay: 0.3s;
}

.artist-section.visible {
    opacity: 1;
    transform: translateY(0);
}

.artist-image {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 15px;
}

.artist-name {
    font-size: 1.2em;
    color: #333;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.artist-name::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    width: 100%;
    height: 1px;
    background: #333;
    transition: width 0.3s ease;
}

.artist-name:hover::after {
    width: 0;
}

/* Narrazione */
.story-narration {
    margin: 30px 0;
    font-size: 1.1em;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.5s ease;
    transition-delay: 0.5s;
}

.story-narration.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Audio player personalizzato */
.audio-player {
    position: fixed;
    bottom: 20px;
    left: 20px;
    transform: none;
    background: rgba(255, 255, 255, 0.9);
    padding: 10px 20px;
    border-radius: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    align-items: center;
    gap: 15px;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.audio-player.visible {
    opacity: 1;
}

/* Stili per la pagina di login */
.login-container {
    max-width: 400px;
    margin: 50px auto;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.login-input {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.login-button {
    background-color: #007bff;
    color: white;
    padding: 12px;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 16px;
}

.login-button:hover {
    background-color: #0056b3;
}

.error {
    color: #dc3545;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 4px;
    padding: 10px;
    margin-bottom: 15px;
    text-align: center;
}

/* Controllo audio della storia */
.story-audio-toggle {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    cursor: pointer;
    z-index: 1000;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.story-audio-toggle:hover {
    transform: scale(1.1);
    background: rgba(255, 255, 255, 1);
}

/* Riutilizzo le stesse classi per l'icona dell'audio e lo stato mutato */
.icon-music {
    position: relative;
    width: 16px;
    height: 16px;
    display: block;
}

.icon-music::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    width: 8px;
    height: 8px;
    background: #333;
    transform: translateY(-50%);
    clip-path: polygon(0 30%, 45% 30%, 45% 0, 100% 0, 100% 100%, 45% 100%, 45% 70%, 0 70%);
}

.icon-music::after {
    content: '';
    position: absolute;
    right: 0;
    top: 50%;
    width: 8px;
    height: 8px;
    transform: translateY(-50%);
    border-right: 2px solid #333;
    border-radius: 0 8px 8px 0;
}

/* Stato mutato */
.music-toggle.muted .icon-music::after {
    display: none;
}

.music-toggle.muted .icon-music::before {
    opacity: 0.5;
}

/* Linea diagonale per lo stato mutato */
.music-toggle.muted::after {
    content: '';
    position: absolute;
    width: 24px;
    height: 2px;
    background: #333;
    transform: rotate(-45deg);
    opacity: 0.7;
}

/* Aggiorna lo stile del pulsante scopri di più */
.btn-discover {
    position: fixed;
    bottom: 20px;
    right: 20px;
    transform: translateY(100px);
    padding: 12px 25px;
    background: rgba(51, 51, 51, 0.9);
    color: #fff;
    text-decoration: none;
    border-radius: 25px;
    opacity: 0;
    transition: all 0.5s ease;
    z-index: 1000;
}

.btn-discover.visible {
    opacity: 1;
    transform: translateY(0);
}

.btn-discover:hover {
    background: rgba(85, 85, 85, 0.95);
    transform: translateY(-2px);
}

/* Stili per l'animazione del testo */
.story-typing-text {
    position: fixed;
    top: 100px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: #333;
    background: rgba(255, 255, 255, 0.9);
    padding: 20px;
    border-radius: 10px;
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.5s ease;
    white-space: pre-line;
    width: 90%;
    max-width: 800px;
    line-height: 1.5;
    overflow-y: auto;
    max-height: 70vh;
}

.story-typing-text.visible {
    opacity: 1;
}

.story-typing-text.fade-out {
    opacity: 0;
}

@keyframes typing {
    from { width: 0 }
    to { width: 100% }
}

/* Desktop */
@media (min-width: 1024px) {
    .story-typing-text {
        font-size: 24px;
        width: 70%;
        padding: 25px;
    }
}

/* Tablet */
@media (min-width: 768px) and (max-width: 1023px) {
    .story-typing-text {
        font-size: 20px;
        width: 80%;
        padding: 20px;
    }
}

/* Smartphone */
@media (max-width: 767px) {
    .story-typing-text {
        font-size: 16px;
        width: 90%;
        padding: 15px;
        top: 70px;
    }
}

/* Stili per il portfolio dell'artista */
.artist-portfolio {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #fff;
    z-index: 1002;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform 0.8s cubic-bezier(0.4, 0, 0.2, 1);
}

.artist-portfolio.visible {
    transform: translateY(0);
}

/* Header del portfolio */
.portfolio-header {
    padding: 40px 20px;
    display: flex;
    align-items: center;
    gap: 30px;
    background: #f8f8f8;
}

.portfolio-artist-image {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
}

.portfolio-artist-info {
    flex: 1;
}

.portfolio-artist-name {
    font-size: 2em;
    margin-bottom: 10px;
}

.portfolio-social-links {
    display: flex;
    gap: 15px;
}

.social-icon {
    width: 24px;
    height: 24px;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.social-icon:hover {
    opacity: 1;
}

/* Biografia */
.portfolio-biography {
    padding: 40px 20px;
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

/* Galleria opere */
.portfolio-gallery {
    padding: 20px;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.portfolio-artwork {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    cursor: pointer;
}

.portfolio-artwork:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.portfolio-artwork img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.portfolio-artwork:hover img {
    transform: scale(1.05);
}

.portfolio-artwork-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 15px;
    background: linear-gradient(to top, rgba(0,0,0,0.8), transparent);
    color: white;
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.portfolio-artwork:hover .portfolio-artwork-info {
    transform: translateY(0);
}

.portfolio-artwork-info h4 {
    margin: 0 0 8px 0;
    font-size: 1.1em;
}

.btn-details,
.artwork-link {
    display: inline-block;
    padding: 12px 24px;
    background-color: #333;
    color: #fff;
    border: none;
    border-radius: 25px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    text-align: center;
}

.btn-details:hover,
.artwork-link:hover {
    background-color: #555;
    transform: translateY(-2px);
}

/* Pulsante chiusura portfolio */
.close-portfolio {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(0,0,0,0.1);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease;
}

.close-portfolio:hover {
    background: rgba(0,0,0,0.2);
}

/* Stile per i pulsanti di navigazione */
.navigation-buttons {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translate(-50%, 100px);
    display: flex;
    gap: 20px;
    opacity: 0;
    transition: all 0.5s ease;
    z-index: 1000;
}

.navigation-buttons.visible {
    transform: translate(-50%, 0);
    opacity: 1;
}

/* Modifica stile pulsanti di navigazione */
.btn-nav {
    background: rgba(51, 51, 51, 0.9);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5em;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.btn-nav:hover {
    background: rgba(85, 85, 85, 0.95);
    transform: translateY(-2px);
}

.btn-nav.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Stili per la galleria */
.artwork-gallery {
    margin-top: 20px;
    padding: 20px;
}

.artwork-gallery h4 {
    margin-bottom: 15px;
    color: #333;
    font-size: 1.2em;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 15px;
    margin-top: 15px;
}

.gallery-item {
    position: relative;
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.3s ease;
}

.gallery-item:hover {
    transform: scale(1.05);
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Stili per la visualizzazione a schermo intero */
.fullscreen-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.9);
    z-index: 1000;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.fullscreen-container.visible {
    opacity: 1;
}

.fullscreen-overlay {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.fullscreen-image {
    max-width: 90%;
    max-height: 90%;
    object-fit: contain;
}

.close-fullscreen {
    position: absolute;
    top: 20px;
    right: 20px;
    background: none;
    border: none;
    color: white;
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
    z-index: 1001;
}

.prev-image,
.next-image {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 24px;
    padding: 20px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.prev-image:hover,
.next-image:hover {
    background: rgba(255, 255, 255, 0.2);
}

.prev-image {
    left: 20px;
}

.next-image {
    right: 20px;
}

/* Menu Hamburger */
.menu-toggle {
    position: fixed;
    top: 20px;
    left: 20px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    border-radius: 50%;
    cursor: pointer;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 6px;
    padding: 8px;
    transition: all 0.3s ease;
}

.menu-toggle:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.1);
}

.menu-toggle span {
    display: block;
    width: 100%;
    height: 2px;
    background: #333;
    transition: all 0.3s ease;
}

.menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Menu Panel */
.menu-panel {
    position: fixed;
    top: 0;
    left: 0;
    width: 300px;
    height: 100vh;
    background: rgba(255, 255, 255, 0.98);
    z-index: 1999;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    padding: 80px 20px 20px;
    display: flex;
    flex-direction: column;
}

.menu-panel.visible {
    transform: translateX(0);
}

.menu-items {
    list-style: none;
    padding: 0;
    margin: 0;
}

.menu-items li {
    margin-bottom: 15px;
}

.menu-items a {
    display: block;
    padding: 10px;
    color: #333;
    text-decoration: none;
    font-size: 1.2em;
    transition: all 0.3s ease;
    border-radius: 8px;
}

.menu-items a:hover {
    background: rgba(0,0,0,0.05);
    padding-left: 20px;
}

.menu-footer {
    margin-top: auto;
    padding-top: 20px;
    border-top: 1px solid #eee;
    font-size: 0.9em;
    color: #666;
    text-align: center;
}

/* Responsive per schermi più piccoli */
@media (max-width: 768px) {
    .emotions-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 12px;
        padding: 12px;
    }

    .emotion-card {
        min-height: 120px;
        padding: 10px;
    }

    .emotion-icon {
        width: 40px;
        height: 40px;
    }

    .emotion-name {
        font-size: 0.95em;
    }
}

/* Media query per smartphone */
@media (max-width: 480px) {
    .emotions-grid {
        grid-template-columns: repeat(2, 1fr); /* Forza 2 colonne */
        gap: 10px;
        padding: 10px;
    }

    .emotion-card {
        min-height: 100px;
        padding: 8px;
    }

    .emotion-icon {
        width: 35px;
        height: 35px;
        margin-bottom: 6px;
    }

    .emotion-name {
        font-size: 0.9em;
        line-height: 1.1;
    }
}

/* Media query per smartphone molto piccoli */
@media (max-width: 320px) {
    .emotions-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
        padding: 8px;
    }

    .emotion-card {
        min-height: 90px;
        padding: 6px;
    }

    .emotion-icon {
        width: 30px;
        height: 30px;
        margin-bottom: 4px;
    }

    .emotion-name {
        font-size: 0.85em;
    }
}

/* Stili esistenti per artist-detail */
.artist-detail {
    display: flex;
    gap: 30px;
    padding: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.artist-image-container {
    flex: 0 0 300px;
}

.artist-image {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.artist-info {
    flex: 1;
}

.artist-bio {
    line-height: 1.6;
    color: #333;
    margin-top: 20px;
}

/* Aggiungiamo media query per smartphone */
@media (max-width: 768px) {
    .artist-detail {
        flex-direction: column;
        padding: 15px;
        gap: 20px;
    }

    .artist-image-container {
        flex: none;
        width: 100%;
        max-width: 300px;
        margin: 0 auto;
    }

    .artist-info {
        width: 100%;
    }

    .artist-bio {
        font-size: 0.95em;
        margin-top: 15px;
        padding: 0 5px;
    }

    /* Previeni overflow orizzontale */
    .artist-info, .artist-bio {
        word-wrap: break-word;
        overflow-wrap: break-word;
        -webkit-hyphens: auto;
        -ms-hyphens: auto;
        hyphens: auto;
    }
}

/* Per schermi molto piccoli */
@media (max-width: 480px) {
    .artist-detail {
        padding: 10px;
        gap: 15px;
    }

    .artist-image-container {
        max-width: 250px;
    }

    .artist-bio {
        font-size: 0.9em;
        line-height: 1.5;
    }
}

.transition-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #000;
    z-index: 2000;
    opacity: 0;
    transition: opacity 0.5s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.transition-container.visible {
    opacity: 1;
}

.transition-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feelings-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 25px;
    max-width: 900px;
    width: 90%;
    margin: 0 auto;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.5s ease, transform 0.5s ease;
    padding: 20px 0;
}

.feelings-grid.visible {
    opacity: 1;
    transform: translateY(0);
}

.feeling-select-card {
    background: #fff;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    cursor: pointer;
    transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    border: 2px solid transparent;
}

.feeling-select-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.feeling-select-card.selected {
    border-color: #333;
    background-color: #f8f8f8;
    transform: scale(1.05);
}

.feeling-select-card img {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 30px;
    margin-bottom: 12px;
    transition: all 0.3s ease;
}

.feeling-select-card:hover img {
    transform: scale(1.05);
}

.feeling-select-card h4 {
    font-size: 1.1em;
    margin: 0;
    color: #333;
}

/* Media queries per responsività */
@media (max-width: 768px) {
    .feelings-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .feeling-select-card {
        padding: 15px 10px;
    }
    
    .feeling-select-card img {
        width: 40px;
        height: 40px;
    }
    
    .feeling-select-card h4 {
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .feelings-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
} 