/* Base styles */
:root {
    --primary-color: #3498db;
    --secondary-color: #2ecc71;
    --background-color: #ffffff;
    --text-color: #333333;
    --light-gray: #f5f5f5;
    --medium-gray: #e0e0e0;
    --dark-gray: #9e9e9e;
    --error-color: #e74c3c;
    --success-color: #2ecc71;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: var(--light-gray);
    color: var(--text-color);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    height: 550px;
}

.container {
    max-width: 1200px; /* Definindo a largura para 1200px */
    width: 100%;  /* Garantir que a largura seja 100% até o limite do max-width */
    margin: 0 auto;
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;  /* Importante para garantir que padding não afete a largura */
}

/* Survey container */
#survey-container {
    background-color: var(--background-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    padding: 30px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    width: 100%;  /* Garantir que o container do survey ocupe toda a largura */
}

/* Logo */
#logo-container {
    text-align: center;
    margin-bottom: 30px;
}

#company-logo {
    max-width: 200px;
    max-height: 80px;
}

/* Survey content */
#survey-content {
    text-align: center;
}

#survey-title {
    font-size: 2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

#survey-question {
    font-size: 1.2rem;
    margin-bottom: 30px;
}

/* Rating options */
#rating-container {
    display: flex;
    justify-content: space-evenly;
    flex-wrap: wrap;
    gap: 15px;
    margin-bottom: 30px;
    width: 100%;
}

.rating-option {
    cursor: pointer;
    padding: 15px;
    border-radius: var(--border-radius);
    background-color: var(--light-gray);
    transition: transform 0.2s, background-color 0.2s;
    width: 120px;
    height: 120px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.rating-option.hovered {
    transform: translateY(-5px);
    background-color: var(--medium-gray);
}

.rating-option.selected {
    background-color: var(--primary-color);
    color: white;
    transform: translateY(-5px);
}

.emoji {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.label {
    font-size: 0.9rem;
    text-align: center;
}

/* Comment section */
#comment-container {
    margin-top: 30px;
    width: 100%; /* Garantir que o comment-container ocupe toda a largura */
}

#comment-container h3 {
    margin-bottom: 15px;
    text-align: center; /* Alinha o título do comentário */
}

#comment-input {
    width: 100%;
    height: 120px;
    padding: 15px;
    border: 1px solid var(--medium-gray);
    border-radius: var(--border-radius);
    resize: none;
    font-family: inherit;
    font-size: 1rem;
    margin-bottom: 15px;
    box-sizing: border-box;
}

/* Buttons */
button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: var(--border-radius);
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s;
    margin: 0 5px;
}

button:hover {
    background-color: #2980b9;
}

#skip-button {
    background-color: var(--dark-gray);
}

#skip-button:hover {
    background-color: #7f8c8d;
}

/* Thank you message */
#thank-you-container {
    text-align: center;
    padding: 40px 0;
}

.thank-you-content {
    animation: fadeIn 0.5s ease-in-out;
}

#thank-you-container i {
    font-size: 5rem;
    color: var(--success-color);
    margin-bottom: 20px;
}

#thank-you-message {
    font-size: 2rem;
    color: var(--primary-color);
}

/* Error message */
#error-container {
    text-align: center;
    padding: 40px 0;
}

.error-content {
    animation: fadeIn 0.5s ease-in-out;
}

#error-container i {
    font-size: 5rem;
    color: var(--error-color);
    margin-bottom: 20px;
}

#error-container h2 {
    font-size: 2rem;
    color: var(--error-color);
    margin-bottom: 15px;
}

#error-message {
    margin-bottom: 20px;
}

#retry-button {
    background-color: var(--error-color);
}

#retry-button:hover {
    background-color: #c0392b;
}

/* Offline message */
#offline-message {
    background-color: #f39c12;
    color: white;
    padding: 15px;
    border-radius: var(--border-radius);
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

#offline-message i {
    font-size: 1.5rem;
    margin-right: 15px;
}

/* Footer */
footer, #survey-footer {
    text-align: center;
    padding: 20px 0;
    color: var(--dark-gray);
    margin-top: auto;
}

.brand {
    font-weight: bold;
    color: var(--primary-color);
}

/* Utility classes */
.hidden {
    display: none !important;
}

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

/* Responsive design */
@media (max-width: 768px) {
    #rating-container {
        gap: 10px;
    }

    .rating-option {
        width: 100px;
        height: 100px;
        padding: 10px;
    }

    .emoji {
        font-size: 2rem;
    }

    .label {
        font-size: 0.8rem;
    }
}

@media (max-width: 480px) {
    #survey-container {
        padding: 20px;
    }

    #rating-container {
        flex-direction: column;
        align-items: center;
    }

    .rating-option {
        width: 80%;
        height: auto;
        padding: 15px;
        flex-direction: row;
        justify-content: flex-start;
    }

    .emoji {
        font-size: 2rem;
        margin-bottom: 0;
        margin-right: 15px;
    }
}

/* Admin logo */
#logo-container-admin {
    text-align: center;
}

#logo-container-admin > img {
    width: 186px;
    height: 74px;
}
