/* --- General Setup & Body --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
}

body {
    font-family: 'Lora', serif;
    background-color: #fdfaf6; /* Warmer, softer background */
    color: #4b3f55; /* A slightly softer dark text color */
    display: flex;
    flex-direction: column; /* To allow for footer */
    justify-content: flex-start;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
    overflow-x: hidden; /* Only hide horizontal overflow */
    overflow-y: auto; /* Allow vertical scrolling */
}

/* Improve default typography rhythm and line-height */
body, input, textarea, button {
    line-height: 1.5;
}

/* --- Animations --- */
@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

@keyframes success {
    0% { 
        opacity: 0;
        transform: scale(0.8) translateY(20px);
    }
    100% { 
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* --- Compact Form Card --- */
.form-card {
    width: 100%;
    max-width: 420px;
    background-color: rgba(255, 255, 255, 0.95);
    transition: all 0.3s ease;
    padding: 24px 28px;
    border-radius: 16px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(230, 219, 232, 0.8);
    position: relative;
    z-index: 2;
    transition: transform 0.35s ease, box-shadow 0.35s ease, background-color 0.35s ease;
    animation: fadeIn 1s ease-out;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.form-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 18px 46px rgba(0, 0, 0, 0.08);
}

h1 {
    font-family: 'Playfair Display', serif;
    text-align: center;
    margin-bottom: 40px;
    font-weight: 700;
    font-size: 2.8rem;
    color: #5d4a6d;
    line-height: 1.2;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.05);
}

/* --- Form Elements --- */
.form-group {
    margin-bottom: 25px;
}

label {
    display: block;
    margin-bottom: 10px;
    font-weight: 400;
    color: #5d4a6d;
    font-size: 1.05rem;
    font-style: italic; /* Elegant italic style for labels */
}

input[type="text"],
textarea {
    width: 100%;
    padding: 14px 18px;
    border: 1px solid #e0d9e4;
    border-radius: 8px;
    background-color: #fdfcfa;
    color: #4b3f55;
    font-family: 'Lora', serif;
    font-size: 1rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.1s ease;
}

input[type="text"]:focus,
textarea:focus {
    outline: none;
    border-color: #b79cd4;
    box-shadow: 0 0 0 4px rgba(183, 156, 212, 0.15);
}

textarea {
    resize: vertical;
    min-height: 100px;
}

::placeholder {
    color: #b0a8b8;
}

/* Inline error text for validation */
.error-text {
    display: none;
    color: #8c445f;
    background: rgba(230, 185, 222, 0.15);
    border: 1px solid rgba(230, 185, 222, 0.5);
    padding: 8px 10px;
    border-radius: 6px;
    margin-top: 8px;
    font-size: 0.9rem;
}

.input-guidance {
    font-size: 0.85rem;
    color: #9b8fa5;
    margin-top: 8px;
    text-align: center;
}

/* --- Buttons --- */
button {
    width: 100%;
    padding: 16px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(145deg, #e6b9de, #d1a5cb);
    color: #ffffff;
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    margin-top: 20px;
    transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 15px rgba(230, 185, 222, 0.4);
}

button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(230, 185, 222, 0.6);
}

button:active {
    transform: translateY(0px);
    box-shadow: 0 2px 10px rgba(230, 185, 222, 0.5);
}

button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* Better focus visibility for accessibility */
input[type="text"]:focus-visible,
textarea:focus-visible,
button:focus-visible,
a:focus-visible {
    outline: none;
    box-shadow: 0 0 0 4px rgba(183, 156, 212, 0.25), 0 0 0 1px #b79cd4;
}

/* --- Form/Success State Transitions --- */
#form-container, #success-message {
    transition: opacity 0.5s ease-in-out, transform 0.5s ease-in-out;
}

.form-submitted #form-container,
.form-submitted .history-container {
    opacity: 0;
    transform: scale(0.95);
    pointer-events: none;
    display: none;
}

/* Keep stats container visible on success page */
.form-submitted .stats-community-container,
.form-submitted .community-stats,
.form-submitted .user-stats {
    display: block !important;
    opacity: 1 !important;
    transform: none !important;
    pointer-events: auto !important;
}

.form-submitted .stats-community-container {
    display: grid !important;
}

#success-message.hidden {
    display: none;
    opacity: 0;
}

.form-submitted #success-message {
    display: block;
    opacity: 1;
    transform: scale(1);
}

#success-message {
    text-align: center;
    animation: success 0.5s ease-out;
}

/* Success state animation */
.form-card.form-submitted #success-message {
    animation: success 0.6s ease-out;
}

/* Enhanced button styles */
button[type="submit"]:disabled {
    background: #b8a7c8;
    cursor: not-allowed;
    transform: none;
    animation: pulse 1.5s infinite;
}

/* Character count styling */
.char-count {
    font-size: 0.8rem;
    color: #666;
    text-align: right;
    margin-top: 4px;
    transition: color 0.2s ease;
}

/* Error banner styling */
.error-banner {
    background: #ffebee;
    border: 1px solid #ffcdd2;
    border-radius: 8px;
    padding: 12px;
    margin: 10px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    animation: slideDown 0.3s ease-out;
}

/* Loading indicator */
.loading-indicator {
    display: inline-block;
    animation: pulse 1.5s infinite;
}

/* Beautiful Compact Stats Layout */
.stats-community-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin: 20px 0;
    max-width: 420px;
}

/* Single card layout for new users */
.stats-community-container.single-card {
    grid-template-columns: 1fr;
    max-width: 420px;
}

.full-width-community {
    max-width: 100%;
}

.user-stats {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.user-stats h3 {
    margin: 0 0 10px 0;
    color: #1f2937;
    font-family: 'Playfair Display', serif;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
}

.stat-item {
    text-align: center;
    padding: 8px 4px;
    background: rgba(249, 250, 251, 0.8);
    border-radius: 6px;
    border: 1px solid rgba(0, 0, 0, 0.04);
}


.stat-item.success {
    border-color: rgba(34, 197, 94, 0.2);
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.05) 0%, rgba(34, 197, 94, 0.02) 100%);
}

.stat-item.pending {
    border-color: rgba(245, 158, 11, 0.2);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.05) 0%, rgba(245, 158, 11, 0.02) 100%);
}

.stat-item.progress {
    border-color: rgba(59, 130, 246, 0.2);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(59, 130, 246, 0.02) 100%);
}

.stat-number {
    display: block;
    font-size: 1.1rem;
    font-weight: 600;
    color: #1f2937;
    font-family: 'Playfair Display', serif;
    margin-bottom: 2px;
}

.stat-label {
    font-size: 0.65rem;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    line-height: 1.2;
    font-weight: 500;
}

.success-rate {
    text-align: center;
    font-size: 0.8rem;
    color: #059669;
    font-weight: 600;
    margin-top: 8px;
    padding: 4px 12px;
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.1) 0%, rgba(34, 197, 94, 0.05) 100%);
    border-radius: 20px;
    display: inline-block;
    border: 1px solid rgba(34, 197, 94, 0.2);
}

/* Minimal Timeline Styles */
.request-timeline {
    margin-top: 15px;
}

.timeline-item {
    margin-bottom: 8px;
    padding: 0;
}

.timeline-item:last-child {
    margin-bottom: 0;
}

.timeline-content {
    background: rgba(255, 255, 255, 0.8);
    padding: 10px 12px;
    border-radius: 6px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.timeline-content:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.1);
}

.timeline-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
}

.song-title {
    margin: 0;
    font-size: 0.9rem;
    font-weight: 500;
    color: #1f2937;
    flex: 1;
    line-height: 1.3;
    cursor: pointer;
    text-decoration: none;
}

.song-title:hover {
    color: #374151;
    text-decoration: underline;
}

.song-title.clickable {
    color: #1f2937;
}

.song-title.clickable:hover {
    color: #111827;
}

.status-badge {
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.65rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

.status-badge.pending {
    background: #f3f4f6;
    color: #6b7280;
}

.status-badge.in_progress {
    background: #f3f4f6;
    color: #4b5563;
}

.status-badge.uploaded {
    background: #f9fafb;
    color: #111827;
}

.status-badge.rejected {
    background: #f3f4f6;
    color: #6b7280;
}

.recent-badge {
    background: #1f2937;
    color: white;
    padding: 1px 4px;
    border-radius: 3px;
    font-size: 0.6rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
    margin-left: 4px;
}

.timeline-meta {
    display: none;
}

.request-notes {
    background: rgba(249, 250, 251, 0.8);
    padding: 8px 10px;
    border-radius: 4px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    font-style: italic;
    color: #6b7280;
    margin: 6px 0 0 0;
    font-size: 0.8rem;
    line-height: 1.4;
}

.timeline-actions {
    display: none;
}

.community-stats {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    padding: 12px;
    border: 1px solid rgba(0, 0, 0, 0.06);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.community-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 10px;
}

.community-stats h3 {
    margin: 0 0 10px 0;
    color: #1f2937;
    font-family: 'Playfair Display', serif;
    font-size: 0.9rem;
    font-weight: 500;
    text-align: center;
}

.channel-info {
    display: flex;
    align-items: center;
    gap: 8px;
    background: rgba(249, 250, 251, 0.8);
    padding: 6px 10px;
    border-radius: 6px;
    margin-bottom: 8px;
    border: 1px solid rgba(0, 0, 0, 0.04);
}

.telegram-logo {
    width: 20px;
    height: 20px;
    background: #6b7280;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 500;
    font-size: 0.8rem;
}

.channel-details {
    flex: 1;
}

.channel-name {
    font-weight: 500;
    color: #1f2937;
    font-size: 0.8rem;
    text-decoration: none;
}

.channel-name:hover {
    text-decoration: underline;
}

.subscriber-count {
    font-size: 0.7rem;
    color: #6b7280;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: 1px;
}

.community-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    margin-bottom: 12px;
}

.community-stat {
    text-align: center;
    padding: 12px 8px;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 12px;
    border: 1px solid rgba(226, 232, 240, 0.6);
    transition: all 0.3s ease;
    position: relative;
    backdrop-filter: blur(4px);
}

.community-stat.highlight {
    border-color: rgba(245, 158, 11, 0.3);
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1) 0%, rgba(245, 158, 11, 0.05) 100%);
    transform: scale(1.02);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.15);
}

.community-stat:hover {
    transform: translateY(-2px);
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
}

.community-stat .stat-number {
    font-size: 1.4rem;
    margin-bottom: 4px;
    font-weight: 700;
    color: #1e293b;
}

.community-stat .stat-label {
    font-size: 0.7rem;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: #64748b;
    font-weight: 500;
}

.queue-info {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid rgba(226, 232, 240, 0.3);
}

.queue-detail {
    font-size: 0.75rem;
    color: #475569;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.8);
    border-radius: 16px;
    border: 1px solid rgba(226, 232, 240, 0.4);
    font-weight: 500;
    backdrop-filter: blur(4px);
}

/* Duplicate Warning */
.duplicate-warning {
    margin: 10px 0;
    animation: slideDown 0.3s ease-out;
}

.warning-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 15px;
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
    border-left: 4px solid #f39c12;
}

.warning-icon {
    font-size: 1.2rem;
    flex-shrink: 0;
}

.warning-text {
    flex: 1;
    font-size: 0.9rem;
    color: #856404;
}

.dismiss-warning {
    background: none;
    border: none;
    color: #856404;
    cursor: pointer;
    font-size: 1.2rem;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s ease;
}

.dismiss-warning:hover {
    background: rgba(133, 100, 4, 0.1);
}

/* Verified Badge */
.verified-badge {
    background: #4caf50;
    color: white;
    padding: 2px 8px;
    border-radius: 10px;
    font-size: 0.8rem;
    margin-left: 8px;
    font-weight: 500;
}

/* Enhanced Mobile Responsiveness */
@media (max-width: 768px) {
    body {
        padding: 10px;
        overflow-x: hidden;
        overflow-y: auto;
        min-height: 100vh;
        justify-content: flex-start;
    }
    
    .form-card {
        max-width: 100%;
        margin: 10px auto;
        padding: 20px 15px;
    }
    
    .stats-community-container {
        grid-template-columns: 1fr;
        gap: 10px;
        margin: 12px 0;
    }
    
    .stats-community-container.single-card {
        grid-template-columns: 1fr;
    }
    
    .user-stats {
        padding: 10px;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }
    
    .stat-item {
        padding: 6px 3px;
    }
    
    .stat-number {
        font-size: 1.1rem;
    }
    
    .stat-label {
        font-size: 0.6rem;
    }
    
    .community-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 6px;
    }
    
    .channel-info {
        padding: 6px 10px;
    }
    
    .telegram-logo {
        width: 20px;
        height: 20px;
        font-size: 0.8rem;
    }
    
    .channel-name {
        font-size: 0.8rem;
    }
    
    .subscriber-count {
        font-size: 0.7rem;
    }
    
    .timeline-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 5px;
    }
    
    .timeline-content {
        margin-left: 15px;
        padding: 12px;
    }
    
    .queue-info {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    
    .warning-content {
        flex-direction: column;
        text-align: center;
        gap: 8px;
    }
    
    .user-stats h3, .community-stats h3 {
        font-size: 1rem;
        margin-bottom: 8px;
    }
    
    .community-stats {
        padding: 10px;
        margin: 10px 0;
    }
    
    .stat-number {
        font-size: 1.1rem;
    }
    
    .stat-label {
        font-size: 0.6rem;
    }
}

@media (max-width: 480px) {
    .form-card {
        padding: 15px 10px;
        margin: 5px;
    }
    
    .user-stats {
        padding: 8px;
        margin: 8px 0;
    }
    
    .user-stats h3, .community-stats h3 {
        font-size: 0.85rem;
        margin-bottom: 6px;
    }
    
    .community-stats {
        padding: 8px;
        margin: 8px 0;
    }
    
    .stats-community-container {
        grid-template-columns: 1fr;
        gap: 8px;
        margin: 10px 0;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 4px;
    }
    
    .stat-item {
        padding: 6px 2px;
    }
    
    .stat-number {
        font-size: 1rem;
    }
    
    .stat-label {
        font-size: 0.55rem;
    }
    
    .success-rate {
        font-size: 0.75rem;
        padding: 2px 6px;
        margin-top: 4px;
    }
    
    .community-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 4px;
    }
    
    .community-stat {
        padding: 6px 4px;
    }
    
    .community-stat .stat-number {
        font-size: 1rem;
    }
    
    .community-stat .stat-label {
        font-size: 0.65rem;
    }
    
    .channel-info {
        padding: 6px 8px;
        margin-bottom: 8px;
    }
    
    .queue-detail {
        font-size: 0.7rem;
        padding: 2px 6px;
    }
    
    .stat-number {
        font-size: 1.3rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
        line-height: 1.2;
    }
    
    .timeline-item {
        margin-bottom: 15px;
    }
    
    .timeline-content {
        margin-left: 10px;
        padding: 10px;
    }
    
    .song-title {
        font-size: 1rem;
        line-height: 1.3;
    }
    
    h1 {
        font-size: 1.8rem;
    }
}

#success-message h2 {
    font-family: 'Playfair Display', serif;
    color: #5d4a6d;
    font-size: 2.2rem;
    margin-bottom: 15px;
}

#success-message p {
    font-size: 1.1rem;
    color: #666666;
    margin-bottom: 30px;
}

/* Bot prompt card */
.bot-prompt {
    display: grid;
    grid-template-columns: auto 1fr auto;
    gap: 12px;
    align-items: center;
    background: rgba(230, 185, 222, 0.12);
    border: 1px solid rgba(230, 185, 222, 0.5);
    padding: 14px 16px;
    border-radius: 12px;
    margin: 0 auto 20px;
}
.bot-emoji { font-size: 1.6rem; }
.bot-text { color: #5d4a6d; font-size: 0.98rem; }
.bot-btn {
    background: #b79cd4;
    color: #fff;
    text-decoration: none;
    padding: 10px 14px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(183,156,212,0.35);
}
.bot-btn:hover { box-shadow: 0 6px 16px rgba(183,156,212,0.5); transform: translateY(-1px); }

/* --- User Info Header (on Request Page) --- */
.user-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 1px solid #e0d9e4;
    font-size: 0.9rem;
}

#welcome-message {
    color: #666;
    font-style: italic;
}

#logout-link {
    color: #b79cd4;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

#logout-link:hover {
    color: #5d4a6d;
}

#logout-link:focus-visible {
    outline: none;
    box-shadow: 0 0 0 3px rgba(183, 156, 212, 0.35);
}

/* --- Song History List --- */
.history-container {
    margin-top: 30px;
    padding: 20px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.history-container h2 {
    font-family: 'Playfair Display', serif;
    color: #1f2937;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 20px;
    text-align: center;
}

.history-instruction {
    font-size: 0.75rem;
    color: #9ca3af;
    text-align: center;
    margin: 0 0 15px 0;
    font-style: italic;
    font-weight: 400;
}

#song-history-list {
    list-style: none;
    padding-left: 0;
    max-height: 240px; /* Prevents list from getting too long */
    overflow-y: auto; /* Adds a scrollbar if needed */
}

#song-history-list li {
    background-color: #f9f6f3;
    padding: 14px 16px;
    border-radius: 6px;
    margin-bottom: 10px;
    font-size: 0.95rem;
    color: #6a5a76;
    border: 1px solid #f0e9f3;
}

/* History layout refinements */
.history-item {
    display: grid;
    grid-template-columns: 1fr auto;
    grid-template-rows: auto auto;
    gap: 4px 12px;
}
.history-title { grid-column: 1 / 2; font-weight: 600; }
.history-meta { grid-column: 1 / 2; font-size: 0.85rem; color: #857394; }
.history-actions { grid-column: 2 / 3; grid-row: 1 / 3; display: flex; align-items: center; }
.history-delete { background: #b79cd4; color: #fff; border: none; border-radius: 6px; padding: 8px 10px; cursor: pointer; box-shadow: 0 2px 8px rgba(183,156,212,0.35); }
.history-delete:hover { transform: translateY(-1px); box-shadow: 0 4px 10px rgba(183,156,212,0.45); }
.history-delete:active { transform: translateY(0); }
.verified-badge { display:inline-block; margin-left:8px; padding:2px 6px; border-radius:999px; background:#e6f3e6; color:#2d6a2d; font-size:0.75rem; border:1px solid #cfe6cf; }

.secondary-btn {
    background: #b79cd4;
    font-size: 0.9rem;
    padding: 10px 20px;
    width: auto;
    display: block;
    margin: 20px auto 0;
}
.secondary-btn.hidden { 
    display: none; 
}

/* --- Footer --- */
footer {
    margin-top: 30px;
    font-size: 0.9rem;
    color: #9b8fa5;
    text-align: center;
    z-index: 2;
}

footer a {
    color: #8c789a;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #5d4a6d;
}

/* --- Animated Background --- */
.background-symbols {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0;
}

.background-symbols span {
    position: absolute;
    color: rgba(93, 74, 109, 0.08); /* Very faint color */
    font-size: 5vw; /* Responsive size */
    animation: float 20s infinite linear;
    user-select: none; /* Not selectable */
    will-change: transform;
}

/* Soft gradient blobs for depth (same palette, low opacity) */
.background-symbols::before,
.background-symbols::after {
    content: "";
    position: absolute;
    inset: -20% -10% -10% -20%;
    background:
        radial-gradient(40% 35% at 20% 30%, rgba(230, 185, 222, 0.20), transparent 60%),
        radial-gradient(35% 40% at 80% 20%, rgba(209, 165, 203, 0.18), transparent 65%),
        radial-gradient(45% 45% at 60% 80%, rgba(93, 74, 109, 0.10), transparent 65%);
    filter: blur(20px);
    z-index: -1;
    animation: auroraDrift 40s linear infinite;
    transform: translate3d(0,0,0) scale(1.05);
    pointer-events: none;
}

.background-symbols::after {
    inset: -15% -20% -20% -10%;
    background:
        radial-gradient(38% 38% at 30% 70%, rgba(230, 185, 222, 0.18), transparent 60%),
        radial-gradient(42% 42% at 75% 50%, rgba(183, 156, 212, 0.18), transparent 65%);
    animation-duration: 55s;
    animation-direction: reverse;
}

.background-symbols span:nth-child(1) { top: 20%; left: 10%; animation-duration: 25s; }
.background-symbols span:nth-child(2) { top: 60%; left: 20%; animation-duration: 30s; font-size: 7vw; }
.background-symbols span:nth-child(3) { top: 10%; left: 50%; animation-duration: 22s; }
.background-symbols span:nth-child(4) { top: 80%; left: 40%; animation-duration: 28s; font-size: 6vw; }
.background-symbols span:nth-child(5) { top: 30%; left: 80%; animation-duration: 24s; }
.background-symbols span:nth-child(6) { top: 5%; left: 90%; animation-duration: 32s; font-size: 8vw; }
.background-symbols span:nth-child(7) { top: 85%; left: 70%; animation-duration: 26s; }
.background-symbols span:nth-child(8) { top: 50%; left: 5%; animation-duration: 29s; }

/* --- Keyframe Animations --- */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes float {
    from { transform: translateY(0) rotate(0deg); }
    to { transform: translateY(-120vh) rotate(360deg); } /* Move from bottom to off-screen top */
}

@keyframes auroraDrift {
    0% {
        transform: translate3d(0, 0, 0) scale(1.05) rotate(0deg);
    }
    25% {
        transform: translate3d(-2%, 1%, 0) scale(1.06) rotate(2deg);
    }
    50% {
        transform: translate3d(1%, -2%, 0) scale(1.04) rotate(-1deg);
    }
    75% {
        transform: translate3d(2%, 1%, 0) scale(1.06) rotate(1deg);
    }
    100% {
        transform: translate3d(0, 0, 0) scale(1.05) rotate(0deg);
    }
}

/* --- Responsiveness --- */
@media (max-width: 600px) {
    .form-card { 
        padding: 28px; 
    }
    h1 { 
        font-size: 2rem; 
    }
    label {
        font-size: 1rem;
    }
    input[type="text"],
    textarea {
        font-size: 1rem;
        padding: 14px 16px;
    }
    button {
        font-size: 1.05rem;
        padding: 15px;
    }
    .user-info {
        font-size: 0.95rem;
    }
}

/* Improve larger screens spacing subtly */
@media (min-width: 900px) {
    .form-card {
        padding: 48px 56px;
    }
}

/* Reduce motion for users who prefer less animation */
@media (prefers-reduced-motion: reduce) {
    * {
        animation: none !important;
        transition: none !important;
    }
}

/* Touch devices: avoid heavy hover transforms */
@media (hover: none) {
    button:hover {
        transform: none;
        box-shadow: 0 4px 15px rgba(230, 185, 222, 0.4);
    }
    .form-card:hover {
        transform: none;
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.07);
    }
}