﻿
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --orange-primary: #F59E0B;
    --orange-secondary: #D97706;
    --orange-light: #FEF3C7;
    --orange-dark: #B45309;
    --orange-soft: #FCD34D;
    --white: #FFFFFF;
    --gray-50: #F9FAFB;
    --gray-100: #F3F4F6;
    --gray-200: #E5E7EB;
    --gray-300: #D1D5DB;
    --gray-400: #9CA3AF;
    --gray-500: #6B7280;
    --gray-600: #4B5563;
    --gray-700: #374151;
    --gray-800: #1F2937;
    --gray-900: #111827;
    --success: #10B981;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
    --radius-sm: 0.375rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-2xl: 1.5rem;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background: linear-gradient(180deg, var(--gray-50) 0%, var(--orange-light) 50%, var(--gray-50) 100%);
    min-height: 100vh;
    color: var(--gray-800);
    line-height: 1.6;
    padding-bottom: 2rem;
}

.container {
    max-width: 760px;
    margin: 0 auto;
    padding: 1rem;
}

.header {
    background: linear-gradient(135deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    border-radius: var(--radius-2xl);
    padding: 2rem 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow-xl);
    text-align: center;
    position: relative;
    overflow: hidden;
}

    .header::before {
        content: '';
        position: absolute;
        top: -50%;
        left: -50%;
        width: 200%;
        height: 200%;
        background: radial-gradient(circle, rgba(255,255,255,0.15) 0%, transparent 70%);
        animation: shimmer 4s infinite linear;
    }

@keyframes shimmer {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }

    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}

.header-content {
    position: relative;
    z-index: 1;
}

.header h1 {
    color: var(--white);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.15);
    line-height: 1.3;
}

.header p {
    color: var(--orange-light);
    font-size: 0.9rem;
    font-weight: 500;
}

.header-logo {
    width: 100%;
    max-width: 450px;
    margin: 0 auto 1rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.card {
    background: var(--white);
    border-radius: var(--radius-xl);
    padding: 1.25rem;
    margin-bottom: 1rem;
    box-shadow: var(--shadow-md);
    transition: var(--transition);
    border: 1px solid var(--gray-200);
}

    .card:hover {
        box-shadow: var(--shadow-lg);
        transform: translateY(-2px);
    }

.card-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--orange-light);
}

.card-icon {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.25rem;
    flex-shrink: 0;
}

.card-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--gray-800);
}

.card-subtitle {
    font-size: 0.8rem;
    color: var(--gray-500);
    margin-top: 0.25rem;
}

.form-group {
    margin-bottom: 1.25rem;
    padding: 0.75rem;
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    transition: var(--transition);
}

    .form-group:hover {
        background: var(--orange-light);
    }

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
}

    .form-label .required {
        color: var(--orange-secondary);
    }

.form-hint {
    font-size: 0.75rem;
    color: var(--gray-500);
    margin-bottom: 0.75rem;
    line-height: 1.4;
}

.star-rating {
    display: flex;
    gap: 0.5rem;
    flex-direction: row-reverse;
    justify-content: flex-end;
}

    .star-rating input {
        display: none;
    }

    .star-rating label {
        font-size: 2rem;
        color: var(--gray-300);
        cursor: pointer;
        transition: var(--transition);
    }

        .star-rating label:hover,
        .star-rating label:hover ~ label,
        .star-rating input:checked ~ label {
            color: #F59E0B;
            transform: scale(1.15);
        }

.emoji-rating {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.emoji-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.4rem;
    cursor: pointer;
    transition: var(--transition);
    padding: 0.8rem 1rem;
    border-radius: var(--radius-lg);
    border: 2px solid transparent;
    background: var(--white);
    min-width: 100px;
}

    .emoji-option:hover {
        background: var(--orange-light);
        transform: scale(1.05);
    }

    .emoji-option input {
        display: none;
    }

        .emoji-option input:checked + .emoji-icon {
            transform: scale(1.2);
        }

    .emoji-option.selected {
        border-color: var(--orange-primary);
        background: var(--orange-light);
    }

.emoji-icon {
    font-size: 2.5rem;
    transition: var(--transition);
}

.emoji-label {
    font-size: 0.75rem;
    color: var(--gray-600);
    text-align: center;
    font-weight: 600;
}

.yes-no-rating {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
}

.yes-no-btn {
    flex: 1;
    padding: 0.9rem;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-lg);
    background: var(--white);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

    .yes-no-btn:hover {
        border-color: var(--orange-primary);
        background: var(--orange-light);
        transform: translateY(-2px);
    }

    .yes-no-btn.yes.active {
        background: var(--success);
        border-color: var(--success);
        color: var(--white);
    }

    .yes-no-btn.no.active {
        background: var(--orange-primary);
        border-color: var(--orange-primary);
        color: var(--white);
    }

.likert-scale {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.4rem;
    margin-top: 0.5rem;
}

.likert-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
}

    .likert-option input {
        display: none;
    }

    .likert-option label {
        width: 100%;
        padding: 0.7rem 0.4rem;
        background: var(--white);
        border: 2px solid var(--gray-200);
        border-radius: var(--radius-md);
        text-align: center;
        font-size: 0.9rem;
        font-weight: 600;
        cursor: pointer;
        transition: var(--transition);
        color: var(--gray-600);
    }

        .likert-option label:hover {
            border-color: var(--orange-primary);
            background: var(--orange-light);
            color: var(--orange-dark);
        }

    .likert-option input:checked + label {
        background: linear-gradient(135deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
        border-color: var(--orange-primary);
        color: var(--white);
        transform: scale(1.05);
    }

.likert-labels {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.4rem;
    margin-top: 0.4rem;
}

.likert-label {
    font-size: 0.65rem;
    text-align: center;
    color: var(--gray-500);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.textarea-input {
    width: 100%;
    padding: 1rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    font-size: 0.9rem;
    font-family: inherit;
    resize: vertical;
    min-height: 90px;
    transition: var(--transition);
    background: var(--white);
}

    .textarea-input:focus {
        outline: none;
        border-color: var(--orange-primary);
        box-shadow: 0 0 0 3px var(--orange-light);
    }

.select-input {
    width: 100%;
    padding: 0.9rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    font-size: 0.9rem;
    font-family: inherit;
    background: var(--white);
    cursor: pointer;
    transition: var(--transition);
}

    .select-input:focus {
        outline: none;
        border-color: var(--orange-primary);
        box-shadow: 0 0 0 3px var(--orange-light);
    }

.submit-btn {
    width: 100%;
    padding: 1.2rem;
    background: linear-gradient(135deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    color: var(--white);
    border: none;
    border-radius: var(--radius-xl);
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin-top: 1.2rem;
}

    .submit-btn:hover {
        transform: translateY(-3px);
        box-shadow: var(--shadow-xl);
    }

    .submit-btn:disabled {
        opacity: 0.6;
        cursor: not-allowed;
        transform: none;
    }

.progress-bar {
    position: sticky;
    top: 0.5rem;
    background: var(--white);
    padding: 0.9rem 1rem;
    border-radius: var(--radius-xl);
    margin-bottom: 1rem;
    box-shadow: var(--shadow-lg);
    z-index: 100;
    border: 1px solid var(--gray-200);
}

.progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 0.8rem;
    color: var(--gray-600);
    font-weight: 600;
}

.progress-track {
    height: 10px;
    background: var(--gray-200);
    border-radius: 5px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    border-radius: 5px;
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.info-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: var(--orange-light);
    border-radius: var(--radius-full);
    font-size: 0.8rem;
    color: var(--orange-dark);
    margin-bottom: 1rem;
    font-weight: 500;
}

.success-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.6);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    backdrop-filter: blur(4px);
}

    .success-modal.active {
        display: flex;
        animation: fadeIn 0.3s ease;
    }

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.success-content {
    background: var(--white);
    border-radius: var(--radius-2xl);
    padding: 2rem;
    text-align: center;
    max-width: 380px;
    width: 100%;
    animation: slideUp 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.success-icon {
    width: 75px;
    height: 75px;
    background: linear-gradient(135deg, var(--success) 0%, #059669 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.2rem;
    font-size: 2.2rem;
    color: var(--white);
    animation: bounce 0.6s ease;
}

@keyframes bounce {
    0%, 100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.1);
    }
}

.success-title {
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 0.5rem;
}

.success-message {
    color: var(--gray-600);
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

.close-btn {
    padding: 0.75rem 2rem;
    background: var(--orange-primary);
    color: var(--white);
    border: none;
    border-radius: var(--radius-lg);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

    .close-btn:hover {
        background: var(--orange-secondary);
        transform: translateY(-2px);
    }

.qr-section {
    text-align: center;
    padding: 1.5rem;
    background: var(--white);
    border-radius: var(--radius-xl);
    margin-top: 1.5rem;
    box-shadow: var(--shadow-md);
}

.qr-code {
    width: 180px;
    height: 180px;
    margin: 0 auto 1rem;
    background: var(--gray-50);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--gray-200);
}

.section-divider {
    height: 3px;
    background: linear-gradient(90deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    border-radius: 2px;
    margin: 1.2rem 0;
}

.auto-id {
    background: linear-gradient(135deg, var(--orange-light) 0%, var(--gray-50) 100%);
    padding: 0.9rem;
    border-radius: var(--radius-lg);
    font-size: 0.85rem;
    color: var(--gray-700);
    text-align: center;
    margin-bottom: 0.5rem;
    border-left: 4px solid var(--orange-primary);
    font-weight: 500;
}

.input-indicator {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
    padding: 0.2rem 0.5rem;
    background: var(--success);
    color: var(--white);
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    font-weight: 600;
    margin-left: 0.5rem;
    opacity: 0;
    transition: var(--transition);
}

    .input-indicator.visible {
        opacity: 1;
    }

.profile-type-container {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.profile-type-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    transition: var(--transition);
    padding: 1rem 1.5rem;
    border-radius: var(--radius-xl);
    border: 3px solid var(--gray-200);
    background: var(--white);
    min-width: 140px;
}

    .profile-type-option:hover {
        border-color: var(--orange-primary);
        background: var(--orange-light);
        transform: translateY(-3px);
    }

    .profile-type-option input {
        display: none;
    }

        .profile-type-option input:checked + .profile-emoji {
            transform: scale(1.15);
        }

    .profile-type-option.selected {
        border-color: var(--orange-primary);
        background: linear-gradient(135deg, var(--orange-light) 0%, var(--orange-soft) 100%);
        box-shadow: var(--shadow-md);
    }

.profile-emoji {
    font-size: 3rem;
    transition: var(--transition);
}

.profile-label {
    font-size: 0.85rem;
    color: var(--gray-700);
    text-align: center;
    font-weight: 600;
}

.titles-input {
    width: 100%;
    padding: 0.9rem;
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    font-size: 0.9rem;
    font-family: inherit;
    resize: vertical;
    min-height: 70px;
    transition: var(--transition);
    background: var(--white);
    margin-top: 0.75rem;
}

    .titles-input:focus {
        outline: none;
        border-color: var(--orange-primary);
        box-shadow: 0 0 0 3px var(--orange-light);
    }

    .titles-input.disabled {
        background: var(--gray-100);
        color: var(--gray-400);
        cursor: not-allowed;
    }

.profile-details {
    display: none;
    margin-top: 1rem;
    padding: 1rem;
    background: var(--white);
    border-radius: var(--radius-lg);
    border: 2px solid var(--orange-light);
}

    .profile-details.active {
        display: block;
        animation: slideDown 0.3s ease;
    }

@keyframes slideDown {
    from {
        transform: translateY(-10px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.gender-options {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.gender-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

    .gender-option input {
        width: 18px;
        height: 18px;
        cursor: pointer;
    }

.role-options {
    display: flex;
    gap: 1rem;
    margin-bottom: 1rem;
}

.role-option {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

    .role-option input {
        width: 18px;
        height: 18px;
        cursor: pointer;
    }

.form-row {
    margin-bottom: 1rem;
}

    .form-row:last-child {
        margin-bottom: 0;
    }

@media (max-width: 640px) {
    .container {
        padding: 0.75rem;
    }

    .header {
        padding: 1.5rem 1rem;
    }

        .header h1 {
            font-size: 1.25rem;
        }

        .header p {
            font-size: 0.85rem;
        }

    .card {
        padding: 1rem;
    }

    .card-header {
        flex-direction: column;
        text-align: center;
    }

    .likert-scale {
        grid-template-columns: repeat(5, 1fr);
        gap: 0.25rem;
    }

    .likert-option label {
        font-size: 0.8rem;
        padding: 0.5rem 0.2rem;
    }

    .likert-label {
        font-size: 0.55rem;
    }

    .emoji-icon {
        font-size: 1.8rem;
    }

    .star-rating label {
        font-size: 1.7rem;
    }

    .yes-no-rating {
        flex-direction: column;
    }

    .yes-no-btn {
        width: 100%;
    }

    .progress-bar {
        top: 0.25rem;
        padding: 0.75rem;
    }

    .profile-type-option {
        min-width: 120px;
        padding: 0.8rem 1rem;
    }

    .profile-emoji {
        font-size: 2.5rem;
    }

    .gender-options,
    .role-options {
        flex-direction: column;
        gap: 0.5rem;
    }
}

@media (min-width: 641px) and (max-width: 768px) {
    .likert-option label {
        font-size: 0.85rem;
        padding: 0.6rem 0.3rem;
    }
}

.fade-in {
    animation: fadeIn 0.5s ease;
}

.scale-in {
    animation: scaleIn 0.3s ease;
}

@keyframes scaleIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.form-group.answered {
    border-left: 3px solid var(--success);
}

.tooltip {
    position: relative;
    cursor: help;
}

    .tooltip::after {
        content: attr(data-tooltip);
        position: absolute;
        bottom: 100%;
        left: 50%;
        transform: translateX(-50%);
        background: var(--gray-800);
        color: var(--white);
        padding: 0.4rem 0.6rem;
        border-radius: var(--radius-md);
        font-size: 0.7rem;
        white-space: nowrap;
        opacity: 0;
        visibility: hidden;
        transition: var(--transition);
    }

    .tooltip:hover::after {
        opacity: 1;
        visibility: visible;
    }

.floating-submit {
    position: fixed;
    bottom: 1rem;
    left: 50%;
    transform: translateX(-50%);
    z-index: 99;
    width: 90%;
    max-width: 400px;
    display: none;
}

    .floating-submit.visible {
        display: block;
        animation: slideUp 0.3s ease;
    }

@media (min-width: 768px) {
    .floating-submit {
        display: none !important;
    }
}

.comment-hint {
    font-size: 0.75rem;
    color: var(--gray-500);
    margin-top: 0.4rem;
    font-style: italic;
}

.fondo-badge {
    display: inline-block;
    padding: 0.3rem 0.8rem;
    background: linear-gradient(135deg, var(--orange-primary) 0%, var(--orange-secondary) 100%);
    color: var(--white);
    border-radius: var(--radius-full);
    font-size: 0.7rem;
    font-weight: 700;
    margin-left: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}


.toast-container {
    position: fixed;
    top: 25px;
    right: 25px;
    z-index: 99999;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.toast {
    min-width: 320px;
    max-width: 420px;
    background: white;
    border-radius: 10px;
    padding: 16px 18px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.15);
    display: flex;
    align-items: flex-start;
    gap: 12px;
    animation: toastSlide .4s ease;
    font-family: system-ui;
}

.toast-icon {
    font-size: 20px;
}

.toast-message {
    flex: 1;
    font-size: 14px;
    line-height: 1.4;
}

.toast-success {
    border-left: 5px solid #27ae60;
}

.toast-error {
    border-left: 5px solid #e74c3c;
}

.toast-warning {
    border-left: 5px solid #f39c12;
}

.toast-info {
    border-left: 5px solid #3498db;
}

@keyframes toastSlide {
    from {
        opacity: 0;
        transform: translateX(40px);
    }

    to {
        opacity: 1;
        transform: translateX(0);
    }
}