/* Google Fonts Import */
@import url('https://fonts.googleapis.com/css2?family=Fredoka:wght@400;500;600;700&family=Comfortaa:wght@400;500;600;700&display=swap');

/* Icon Styling */
.fas, .far, .fab {
    margin-right: 0.3rem;
    font-size: 0.9em;
}

.feature-icon i, .highlight-icon i, .activity-icon i {
    font-size: 1.2em;
    margin-right: 0;
}

.success-icon i {
    font-size: 2rem;
    color: #28a745;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Tahoma, sans-serif;
    line-height: 1.6;
    color: #333;
    background: #BFD0DA;
    min-height: 100vh;
}

/* High Contrast Mode Support */
@media (prefers-contrast: high) {
    body {
        background: #000;
        color: #fff;
    }
}

/* Reduced Motion Support */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* Login Required Overlay */
.login-required-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: #BFD0DA;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    padding: 2rem;
    overflow-y: auto;
}

.login-required-content {
    background: #E3D2CE;
    border-radius: 20px;
    padding: 3rem;
    max-width: 600px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.2);
    animation: fadeInUp 0.6s ease-out;
    margin: auto;
    max-height: 90vh;
    overflow-y: auto;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 0.5rem;
}

.logo-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
}

.sound-waves {
    position: absolute;
    left: 30px;
    display: flex;
    align-items: center;
    gap: 5px;
}

.wave {
    width: 8px;
    background: #2d3748;
    border-radius: 4px;
    animation: waveAnimation 2s ease-in-out infinite;
}

.wave-1 {
    height: 35px;
    animation-delay: 0s;
}

.wave-2 {
    height: 50px;
    animation-delay: 0.3s;
}

.wave-3 {
    height: 42px;
    animation-delay: 0.6s;
}

@keyframes waveAnimation {
    0%, 100% { 
        transform: scaleY(1);
        opacity: 0.7;
    }
    50% { 
        transform: scaleY(0.3);
        opacity: 1;
    }
}



.brand-logo h1 {
    color: #2d3748;
    font-family: 'Fredoka', sans-serif;
    font-size: 4.2rem;
    margin: 0;
    font-weight: 600;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.1);
    letter-spacing: -0.02em;
}

.tagline {
    color: #666;
    font-size: 1.2rem;
    font-style: italic;
    margin-bottom: 2rem;
}

.welcome-message h2 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 2rem;
}

.welcome-message p {
    color: #666;
    font-size: 1.1rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.feature-highlights {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin: 2rem 0;
}

.highlight-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 10px;
    font-weight: 500;
    color: #333;
}

.highlight-icon {
    font-size: 1.5rem;
}

.auth-prompt {
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 2px solid #eee;
}

.auth-prompt p {
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.auth-prompt-btn {
    background: #2d3748;
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 44px;
}

.auth-prompt-btn:hover, .auth-prompt-btn:focus {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(45, 55, 72, 0.4);
    outline: none;
    background: #1a202c;
}

.auth-prompt-btn:focus {
    box-shadow: 0 10px 25px rgba(45, 55, 72, 0.4), 0 0 0 3px rgba(45, 55, 72, 0.3);
}

/* Mobile responsive for login overlay */
@media (max-width: 768px) {
    .login-required-overlay {
        padding: 1rem;
        align-items: flex-start;
    }
    
    .login-required-content {
        padding: 2rem;
        margin: 1rem auto;
        max-height: calc(100vh - 2rem);
    }
    
    .brand-logo h1 {
        font-size: 3.6rem;
        font-family: 'Fredoka', sans-serif;
    }
    
    .feature-highlights {
        grid-template-columns: 1fr;
    }
    
    .highlight-item {
        justify-content: center;
    }
    
    /* Modal mobile improvements */
    .modal {
        padding: 1rem 0;
    }
    
    .modal-content {
        margin: 1rem auto;
        padding: 1.5rem;
        width: 95%;
        max-height: calc(100vh - 2rem);
        border-radius: 10px;
    }
    
    .auth-form .form-group {
        margin-bottom: 1.25rem;
    }
    
    .close {
        font-size: 24px;
        right: 0.75rem;
        top: 0.75rem;
    }
}

/* Navigation */
.navbar {
    background: rgba(227, 210, 206, 0.95);
    backdrop-filter: blur(10px);
    padding: 1rem 0;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-logo-icon {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
}

.nav-sound-waves {
    position: absolute;
    left: 20px;
    display: flex;
    align-items: center;
    gap: 3px;
}

.nav-wave {
    width: 4px;
    background: #2d3748;
    border-radius: 2px;
    animation: navWaveAnimation 1.5s ease-in-out infinite;
}

.nav-wave:nth-child(1) {
    height: 16px;
    animation-delay: 0s;
}

.nav-wave:nth-child(2) {
    height: 25px;
    animation-delay: 0.2s;
}

.nav-wave:nth-child(3) {
    height: 20px;
    animation-delay: 0.4s;
}

@keyframes navWaveAnimation {
    0%, 100% { transform: scaleY(1); }
    50% { transform: scaleY(0.5); }
}



.nav-brand h1 {
    color: #2d3748;
    font-family: 'Fredoka', sans-serif;
    font-size: 2.5rem;
    font-weight: 600;
    margin: 0;
    letter-spacing: -0.01em;
}

.nav-links {
    display: flex;
    gap: 1rem;
}

.nav-btn {
    background: none;
    border: 2px solid transparent;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 700;
    color: #333;
    transition: all 0.3s ease;
    min-height: 44px; /* Touch target size */
}

.nav-btn:hover, .nav-btn:focus {
    background: #8BB0BA;
    color: white;
    border-color: #8BB0BA;
    outline: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(139, 176, 186, 0.3);
}

.nav-btn:focus {
    box-shadow: 0 0 0 3px rgba(139, 176, 186, 0.3);
}

/* Main Content */
.main-content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.content-section {
    display: none;
    background: #E3D2CE;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    margin-bottom: 2rem;
    position: relative;
}

.content-section.active {
    display: block;
}

.content-section h2 {
    color: #333;
    margin-bottom: 1.5rem;
    font-size: 2rem;
    text-align: center;
}

/* Child Photo Corner */
.child-photo-corner {
    position: absolute;
    top: 20px;
    right: 20px;
    z-index: 100;
    animation: photoFloat 6s ease-in-out infinite;
}

.child-photo-container {
    position: relative;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    border: 4px solid #E3D2CE;
    transition: all 0.3s ease;
    cursor: pointer;
}

.child-photo-container:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
    border-color: #071F35;
}

.child-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    transition: all 0.3s ease;
}

.child-photo-container:hover .child-photo {
    transform: scale(1.05);
}

.photo-caption {
    position: absolute;
    bottom: -35px;
    left: 50%;
    transform: translateX(-50%);
    background: #071F35;
    color: white;
    padding: 0.5rem 1rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: bold;
    white-space: nowrap;
    opacity: 0;
    transition: all 0.3s ease;
    box-shadow: 0 5px 15px rgba(7, 31, 53, 0.3);
}

.child-photo-container:hover .photo-caption {
    opacity: 1;
    bottom: -40px;
}

.caption-text {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

@keyframes photoFloat {
    0%, 100% {
        transform: translateY(0px) rotate(0deg);
    }
    25% {
        transform: translateY(-10px) rotate(1deg);
    }
    50% {
        transform: translateY(-5px) rotate(-1deg);
    }
    75% {
        transform: translateY(-15px) rotate(0.5deg);
    }
}

/* Home Section - Natural Design */
.hero-section {
    padding: 3rem 0;
    text-align: center;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    margin-bottom: 3rem;
    position: relative;
}

.hero-content h2 {
    font-size: 2.5rem;
    color: #2d3748;
    margin-bottom: 1rem;
    font-weight: 600;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: #4a5568;
    margin-bottom: 2.5rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.hero-stats {
    display: flex;
    justify-content: center;
    gap: 3rem;
    margin-top: 2rem;
}

.stat-item {
    text-align: center;
}

.stat-number {
    display: block;
    font-size: 2.5rem;
    font-weight: 700;
    color: #2d3748;
    line-height: 1;
}

.stat-label {
    display: block;
    font-size: 0.9rem;
    color: #718096;
    margin-top: 0.5rem;
    text-transform: lowercase;
}

/* Features Section */
.features-section {
    margin-bottom: 3rem;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-header h3 {
    font-size: 2rem;
    color: #2d3748;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.section-header p {
    font-size: 1.1rem;
    color: #4a5568;
    max-width: 500px;
    margin: 0 auto;
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    max-width: 800px;
    margin: 0 auto;
}

.feature-item {
    display: flex;
    align-items: flex-start;
    gap: 1.5rem;
    padding: 2rem;
    background: rgba(255, 255, 255, 0.6);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.8);
    cursor: pointer;
    transition: all 0.2s ease;
}

.feature-item:hover {
    border-color: rgba(255, 255, 255, 1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
    background: rgba(255, 255, 255, 0.8);
}

.feature-icon {
    font-size: 2rem;
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.4);
}

.feature-content {
    flex: 1;
}

.feature-content h4 {
    font-size: 1.3rem;
    color: #2d3748;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.feature-content p {
    color: #4a5568;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.feature-link {
    color: #2d3748;
    font-weight: 500;
    font-size: 0.95rem;
}

.feature-item:hover .feature-link {
    color: #1a202c;
}

/* Getting Started Section */
.getting-started {
    background: rgba(255, 255, 255, 0.4);
    padding: 2.5rem;
    border-radius: 15px;
    text-align: center;
    margin-bottom: 3rem;
    border: 1px solid rgba(255, 255, 255, 0.6);
}

.start-content h3 {
    font-size: 1.8rem;
    color: #2d3748;
    margin-bottom: 1rem;
    font-weight: 600;
}

.start-content p {
    font-size: 1.1rem;
    color: #4a5568;
    margin-bottom: 2rem;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
}

.quick-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.action-btn {
    padding: 0.875rem 1.75rem;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    border: none;
    font-size: 1rem;
    min-height: 44px;
}

.action-btn.primary {
    background: #2d3748;
    color: white;
}

.action-btn.primary:hover, .action-btn.primary:focus {
    background: #1a202c;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(45, 55, 72, 0.3);
}

.action-btn.secondary {
    background: rgba(255, 255, 255, 0.8);
    color: #2d3748;
    border: 1px solid rgba(255, 255, 255, 0.9);
}

.action-btn.secondary:hover, .action-btn.secondary:focus {
    border-color: rgba(255, 255, 255, 1);
    background: rgba(255, 255, 255, 0.9);
}

/* About Section */
.about-section {
    text-align: center;
    padding: 2rem 0;
}

.about-content h4 {
    font-size: 1.5rem;
    color: #2d3748;
    margin-bottom: 1rem;
    font-weight: 600;
}

.about-content p {
    font-size: 1.1rem;
    color: #4a5568;
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto 2rem;
}

.team-note {
    background: rgba(255, 255, 255, 0.3);
    padding: 1.5rem;
    border-radius: 10px;
    border-left: 4px solid #2d3748;
    max-width: 500px;
    margin: 0 auto;
}

.team-note p {
    margin: 0;
    font-size: 1rem;
    color: #4a5568;
    font-style: italic;
}

/* Authentication Modal */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow-y: auto;
    padding: 2rem 0;
}

.modal-content {
    background-color: white;
    margin: 2rem auto;
    padding: 2rem;
    border-radius: 15px;
    width: 90%;
    max-width: 500px;
    position: relative;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
}

.close {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    position: absolute;
    right: 1rem;
    top: 1rem;
}

.close:hover, .close:focus {
    color: #000;
}

.auth-tabs {
    display: flex;
    margin-bottom: 2rem;
    border-bottom: 2px solid #eee;
}

.tab-btn {
    flex: 1;
    padding: 1rem;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    color: #666;
    border-bottom: 2px solid transparent;
    transition: all 0.3s ease;
}

.tab-btn.active {
    color: #071F35;
    border-bottom-color: #071F35;
}

.auth-form {
    display: block;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.1);
}

.form-group small {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.875rem;
}

.auth-submit-btn {
    width: 100%;
    padding: 1rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.auth-submit-btn:hover, .auth-submit-btn:focus {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

/* Notes Section Layout */
.notes-layout {
    display: block;
    background: #f8f9fa;
    border-radius: 15px;
    padding: 2rem;
    border: 2px solid #e9ecef;
    min-height: 600px;
}

.pdf-speech-section,
.notes-section {
    background: transparent;
    border-radius: 0;
    padding: 1.5rem;
    border: none;
    min-height: 600px;
    display: flex;
    flex-direction: column;
}

.pdf-speech-section h3,
.notes-section h3 {
    color: #333;
    margin-bottom: 1rem;
    font-size: 1.3rem;
    text-align: left;
    border-bottom: none;
    padding-bottom: 0;
    font-weight: bold;
}

/* Note Title Input */
.note-title-container {
    margin-bottom: 1rem;
}

.note-title-input {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    background: white;
    transition: border-color 0.3s ease;
}

.note-title-input:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.1);
}

/* Redesigned Notes Controls */
.notes-controls-redesigned {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1rem;
    flex-wrap: wrap;
}

.speech-controls-left {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.notes-actions-right {
    display: flex;
    gap: 0.5rem;
    margin-left: auto;
}

/* Uniform Control Buttons */
.control-btn-uniform {
    padding: 0.75rem 1rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: bold;
    transition: all 0.3s ease;
    min-height: 44px;
    min-width: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.control-btn-uniform:hover:not(:disabled) {
    background: #0A2A47;
    transform: translateY(-2px);
}

.control-btn-uniform:disabled {
    background: #ccc;
    color: #071F35;
    cursor: not-allowed;
    opacity: 0.6;
}

.control-btn-uniform:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.3);
}

/* Enhanced Note Item Display */
.note-item {
    background: white;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.3s ease;
}

.note-item:hover {
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.note-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.5rem;
    gap: 1rem;
}

.note-title {
    font-weight: bold;
    font-size: 1.1rem;
    color: #071F35;
    flex: 1;
}

.note-date {
    font-size: 0.85rem;
    color: #666;
    white-space: nowrap;
}

.note-content {
    color: #333;
    line-height: 1.4;
    margin-bottom: 0.75rem;
}

.note-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: flex-end;
}

.note-actions button {
    padding: 0.25rem 0.5rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
    transition: background 0.3s ease;
}

.note-actions button:hover {
    background: #0A2A47;
}

/* PDF Upload Area */
.pdf-upload-area {
    border: 3px dashed #071F35;
    border-radius: 10px;
    padding: 2rem 1rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    text-align: center;
}

.pdf-upload-area:hover, .pdf-upload-area:focus-within {
    border-color: #071F35;
    background: rgba(7, 31, 53, 0.05);
}

.pdf-upload-area.highlight {
    border-color: #28a745;
    background: rgba(40, 167, 69, 0.1);
    transform: scale(1.02);
}

.pdf-upload-area input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    top: 0;
    left: 0;
}

.pdf-upload-area .upload-text p {
    font-size: 1.1rem;
    color: #071F35;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.pdf-upload-area .upload-text small {
    color: #666;
    font-size: 0.9rem;
}

/* PDF Controls */
.pdf-controls {
    background: rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.pdf-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding: 0.5rem;
    background: #f8f9fa;
    border-radius: 5px;
}

.pdf-info span:first-child {
    font-weight: 500;
    color: #333;
}

.pdf-info span:last-child {
    color: #071F35;
    font-size: 0.9rem;
}

.speech-settings {
    margin-top: 1rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.setting-row {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.setting-row:last-child {
    margin-bottom: 0;
}

.speech-settings label {
    font-weight: 500;
    color: #333;
    min-width: 60px;
    font-size: 0.9rem;
}

.speech-settings input[type="range"] {
    flex: 1;
    margin: 0 0.5rem;
    accent-color: #071F35;
}

.speech-settings select {
    flex: 1;
    padding: 0.4rem;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 0.9rem;
    background: white;
}

.speech-settings select:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 2px rgba(7, 31, 53, 0.2);
}

.speech-settings span {
    min-width: 35px;
    text-align: center;
    font-weight: 500;
    color: #071F35;
    font-size: 0.9rem;
}

/* PDF Text Display */
.pdf-text-display {
    background: white;
    border-radius: 10px;
    padding: 1rem;
    flex: 1;
    min-height: 200px;
    max-height: 300px;
    overflow-y: auto;
    border: 1px solid #ddd;
}

.pdf-text-content {
    line-height: 1.6;
    color: #333;
    font-size: 1rem;
    font-weight: bold;
}

.pdf-text-content.reading {
    position: relative;
}

.pdf-text-content .highlight {
    background: #fff3cd;
    padding: 2px 4px;
    border-radius: 3px;
    animation: pulse 1s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Reading Progress */
.reading-progress {
    margin-top: 1rem;
    padding: 0.5rem;
    background: #f8f9fa;
    border-radius: 5px;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-fill {
    height: 100%;
    background: #071F35;
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

#progressText {
    font-size: 0.9rem;
    color: #666;
    text-align: center;
    display: block;
}

/* Notes Controls */
.notes-controls {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.5);
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

.speech-controls,
.notes-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.control-btn {
    padding: 0.75rem 1rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: bold;
    transition: all 0.3s ease;
    min-height: 44px;
}

.control-btn:hover:not(:disabled) {
    background: #0A2A47;
    transform: translateY(-2px);
}

.control-btn:disabled {
    background: #ccc;
    color: #071F35;
    cursor: not-allowed;
    opacity: 0.6;
}

.control-btn:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.3);
}

.notes-container {
    margin-bottom: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
    font-weight: bold;
}

#notesText {
    width: 100%;
    padding: 1rem;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 1rem;
    line-height: 1.6;
    resize: vertical;
    min-height: 300px;
    font-weight: bold;
}

#notesText:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.1);
}

.saved-notes {
    background: transparent;
    padding: 1rem 0;
    border-radius: 0;
    flex: 1;
    min-height: 200px;
    font-weight: bold;
}

.saved-notes h3 {
    margin-bottom: 1rem;
    color: #333;
    font-weight: bold;
}

.note-item {
    background: white;
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 8px;
    border-left: 4px solid #071F35;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.note-item .note-date {
    font-size: 0.875rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.note-item .note-content {
    color: #333;
    line-height: 1.5;
    font-weight: bold;
}

.note-actions {
    margin-top: 0.5rem;
    display: flex;
    gap: 0.5rem;
}

.note-actions button {
    padding: 0.25rem 0.5rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.8rem;
}

/* Flashcards Section */
.ai-status {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border-radius: 10px;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border: 2px solid #dee2e6;
}

.status-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    font-weight: 500;
}

.ai-status.connected {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-color: #28a745;
}

.ai-status.connected #aiStatusIcon {
    color: #28a745;
}

.ai-status.error {
    background: linear-gradient(135deg, #f8d7da 0%, #f5c6cb 100%);
    border-color: #dc3545;
}

.ai-status.error #aiStatusIcon {
    color: #dc3545;
}

.ai-status.fallback {
    background: linear-gradient(135deg, #fff3cd 0%, #ffeaa7 100%);
    border-color: #ffc107;
}

.ai-status.fallback #aiStatusIcon {
    color: #856404;
}

.upload-section {
    text-align: center;
    margin-bottom: 2rem;
}

.upload-area {
    border: 3px dashed #071F35;
    border-radius: 15px;
    padding: 3rem 2rem;
    margin-bottom: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.upload-area:hover, .upload-area:focus-within {
    border-color: #071F35;
    background: rgba(7, 31, 53, 0.05);
}

.upload-area input[type="file"] {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}

.upload-text p {
    font-size: 1.2rem;
    color: #071F35;
    margin-bottom: 0.5rem;
}

.upload-text small {
    color: #666;
}

.generate-btn {
    padding: 1rem 2rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 25px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 44px;
}

.generate-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 10px 25px rgba(7, 31, 53, 0.4);
}

.generate-btn:disabled {
    background: #ccc;
    color: #071F35;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.flashcards-container {
    margin-top: 2rem;
}

.flashcard-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 10px;
}

.card-nav-btn {
    padding: 0.75rem 1.5rem;
    background: #071F35;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    min-height: 44px;
}

.card-nav-btn:hover:not(:disabled) {
    background: #0A2A47;
    transform: translateY(-2px);
}

.card-nav-btn:disabled {
    background: #ccc;
    color: #071F35;
    cursor: not-allowed;
}

#cardCounter {
    font-weight: 600;
    color: #333;
    font-size: 1.1rem;
}

.flashcard {
    background: white;
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    border: 2px solid transparent;
}

.flashcard:hover, .flashcard:focus {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
    border-color: #071F35;
}

.flashcard.flipped {
    background: #071F35;
    color: white;
}

.flashcard-content {
    font-size: 1.2rem;
    line-height: 1.6;
}

/* Profile Section */
.profile-container {
    max-width: 600px;
    margin: 0 auto;
}

.profile-card {
    background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%);
    border-radius: 15px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.profile-header {
    display: flex;
    align-items: center;
    margin-bottom: 2rem;
    gap: 1.5rem;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #071F35;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    font-weight: bold;
}

.profile-info h3 {
    color: #333;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.profile-info p {
    color: #666;
    font-size: 1.1rem;
}

.profile-details {
    margin-bottom: 2rem;
}

.detail-item {
    display: flex;
    margin-bottom: 1rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.7);
    border-radius: 8px;
}

.detail-item label {
    font-weight: 600;
    color: #333;
    min-width: 200px;
    text-align: left;
    margin-right: 1rem;
}

.detail-item span,
.detail-item p {
    color: #666;
    flex: 1;
    margin: 0;
}

/* Editable Profile Inputs */
.profile-input {
    flex: 1;
    padding: 0.5rem;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 0.95rem;
    background: white;
    transition: border-color 0.3s ease;
    margin: 0;
}

.profile-input:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.1);
}

.profile-textarea {
    resize: vertical;
    min-height: 60px;
    font-family: inherit;
}

.profile-input::placeholder {
    color: #999;
    font-style: italic;
}

.profile-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.profile-btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
    min-height: 44px;
}

.profile-btn:not(.logout) {
    background: #071F35;
    color: white;
}

.profile-btn.logout {
    background: #dc3545;
    color: white;
}

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

/* Loading and Toast */
.loading {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
    z-index: 3000;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #071F35;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 1rem;
}

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

.toast {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #333;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
    transform: translateX(400px);
    transition: transform 0.3s ease;
    z-index: 4000;
    max-width: 300px;
}

.toast.show {
    transform: translateX(0);
}

.toast.success {
    background: #28a745;
}

.toast.error {
    background: #dc3545;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 1rem;
        padding: 0 1rem;
    }
    
    .nav-links {
        flex-wrap: wrap;
        justify-content: center;
    }
    
    .main-content {
        padding: 0 1rem;
    }
    
    .content-section {
        padding: 1.5rem;
    }
    
    /* Mobile Home Section */
    .hero-content h2 {
        font-size: 2rem;
    }
    
    .hero-subtitle {
        font-size: 1.1rem;
    }
    
    .hero-stats {
        gap: 2rem;
    }
    
    .stat-number {
        font-size: 2rem;
    }
    
    .feature-item {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .feature-icon {
        margin: 0 auto;
    }
    
    .quick-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .action-btn {
        width: 100%;
        max-width: 280px;
    }
    
    /* Child Photo Mobile */
    .child-photo-corner {
        top: 10px;
        right: 10px;
    }
    
    .child-photo-container {
        width: 80px;
        height: 80px;
        border-width: 3px;
    }
    
    .photo-caption {
        font-size: 0.7rem;
        padding: 0.25rem 0.75rem;
        bottom: -30px;
    }
    
    .child-photo-container:hover .photo-caption {
        bottom: -35px;
    }
    
    /* Notes Layout Mobile */
    .notes-layout {
        padding: 1.5rem;
        min-height: 400px;
    }
    
    .pdf-speech-section,
    .notes-section {
        padding: 1rem 0;
        min-height: auto;
    }

    /* Mobile Notes Controls */
    .notes-controls-redesigned {
        flex-direction: column;
        gap: 1rem;
    }

    .speech-controls-left {
        justify-content: center;
    }

    .notes-actions-right {
        margin-left: 0;
        justify-content: center;
    }

    .control-btn-uniform {
        min-width: 100px;
        font-size: 0.8rem;
    }
    
    .notes-controls {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .speech-controls,
    .notes-actions {
        justify-content: center;
    }
    
    .speech-settings {
        padding: 0.75rem;
    }
    
    .setting-row {
        flex-direction: column;
        align-items: stretch;
        gap: 0.25rem;
        margin-bottom: 1rem;
    }
    
    .speech-settings label {
        min-width: auto;
        text-align: left;
        margin-bottom: 0.25rem;
    }
    
    .speech-settings input[type="range"],
    .speech-settings select {
        width: 100%;
        margin: 0;
    }
    
    .speech-settings span {
        text-align: center;
        margin-top: 0.25rem;
    }
    
    .pdf-text-display {
        max-height: 200px;
    }
    
    .profile-header {
        flex-direction: column;
        text-align: center;
    }
    
    .profile-actions {
        flex-direction: column;
    }
    
    .flashcard-controls {
        flex-direction: column;
        gap: 1rem;
    }
}

/* Focus Indicators for Accessibility */
button:focus,
input:focus,
select:focus,
textarea:focus,
.feature-card:focus,
.flashcard:focus {
    outline: 3px solid #071F35;
    outline-offset: 2px;
}

/* Screen Reader Only Content */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Feedback Section */
.feedback-container {
    max-width: 800px;
    margin: 0 auto;
}

.feedback-intro {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    padding: 1.5rem;
    border-radius: 10px;
    margin-bottom: 2rem;
    border-left: 4px solid #071F35;
}

.feedback-intro p {
    margin: 0;
    color: #333;
    font-size: 1.1rem;
    line-height: 1.6;
}

.feedback-form {
    background: white;
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border: 2px solid #f0f0f0;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.feedback-form .form-group {
    margin-bottom: 1.5rem;
}

.feedback-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: #333;
    font-size: 1rem;
}

.feedback-form input,
.feedback-form select,
.feedback-form textarea {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.feedback-form input:focus,
.feedback-form select:focus,
.feedback-form textarea:focus {
    outline: none;
    border-color: #071F35;
    box-shadow: 0 0 0 3px rgba(7, 31, 53, 0.1);
}

.feedback-form small {
    display: block;
    margin-top: 0.25rem;
    color: #666;
    font-size: 0.875rem;
    line-height: 1.4;
}

/* Radio Button Styling */
input[type="radio"] {
    appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #071F35;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

input[type="radio"]:checked {
    background: #071F35;
    border-color: #071F35;
}

input[type="radio"]:checked::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: white;
}

input[type="radio"]:focus {
    outline: 3px solid rgba(7, 31, 53, 0.3);
    outline-offset: 2px;
}

input[type="radio"]:hover {
    border-color: #0A2A47;
}

/* Star Rating */
.rating-container {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.star-rating {
    display: flex;
    flex-direction: row-reverse;
    gap: 0.25rem;
}

.star-rating input {
    display: none;
}

.star-rating label {
    font-size: 2rem;
    color: #ddd;
    cursor: pointer;
    transition: color 0.2s ease;
    margin: 0;
    padding: 0.25rem;
}

.star-rating label:hover,
.star-rating label:hover ~ label,
.star-rating input:checked ~ label {
    color: #071F35;
}

.rating-text {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

/* Character Counter */
.char-counter {
    text-align: right;
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: #666;
}

.char-counter.warning {
    color: #ff6b35;
}

.char-counter.danger {
    color: #dc3545;
}

/* Checkbox Groups */
.checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
}

.checkbox-group input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.checkbox-group label {
    margin: 0;
    font-weight: 500;
    cursor: pointer;
}

/* Form Actions */
.form-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 2px solid #f0f0f0;
}

.btn-primary,
.btn-secondary {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 44px;
    min-width: 120px;
}

.btn-primary {
    background: #071F35;
    color: white;
}

.btn-primary:hover, .btn-primary:focus {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(7, 31, 53, 0.4);
}

.btn-secondary {
    background: #f8f9fa;
    color: #333;
    border: 2px solid #ddd;
}

.btn-secondary:hover, .btn-secondary:focus {
    background: #e9ecef;
    border-color: #adb5bd;
}

/* Success Message */
.feedback-success {
    text-align: center;
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    padding: 3rem 2rem;
    border-radius: 15px;
    border: 2px solid #28a745;
}

.success-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
}

.feedback-success h3 {
    color: #155724;
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.feedback-success p {
    color: #155724;
    margin-bottom: 1rem;
    line-height: 1.6;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .feedback-form {
        padding: 1.5rem;
    }
    
    .form-actions {
        flex-direction: column;
    }
    
    .star-rating label {
        font-size: 1.5rem;
    }
    
    .rating-container {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.5rem;
    }
}

/* Rewards System Styles */
.rewards-container {
    max-width: 1200px;
    margin: 0 auto;
}

.balance-card {
    background: linear-gradient(135deg, #071F35 0%, #0A2A47 100%);
    color: white;
    border-radius: 20px;
    padding: 2rem;
    margin-bottom: 2rem;
    box-shadow: 0 10px 30px rgba(7, 31, 53, 0.3);
}

.balance-header {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.fruit-basket {
    display: flex;
    gap: 0.5rem;
    font-size: 3rem;
    animation: fruitBounce 2s ease-in-out infinite;
}

.fruit-icon {
    animation: fruitFloat 3s ease-in-out infinite;
    animation-delay: calc(var(--i) * 0.5s);
}

.fruit-icon:nth-child(1) { --i: 0; }
.fruit-icon:nth-child(2) { --i: 1; }
.fruit-icon:nth-child(3) { --i: 2; }
.fruit-icon:nth-child(4) { --i: 3; }

@keyframes fruitBounce {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-10px); }
}

@keyframes fruitFloat {
    0%, 100% { transform: rotate(0deg) scale(1); }
    25% { transform: rotate(-5deg) scale(1.1); }
    50% { transform: rotate(0deg) scale(1); }
    75% { transform: rotate(5deg) scale(1.1); }
}

.fruit-counter-display {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 15px;
}

.fruit-count-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 10px;
    transition: all 0.3s ease;
}

.fruit-count-item:hover {
    transform: scale(1.05);
    background: rgba(255, 255, 255, 0.4);
}

.fruit-emoji {
    font-size: 2rem;
    animation: fruitPulse 2s ease-in-out infinite;
}

.fruit-count {
    font-size: 1.2rem;
    font-weight: bold;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

@keyframes fruitPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.1); }
}

.balance-info h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    font-weight: bold;
}

.balance-amount {
    font-size: 3rem;
    font-weight: bold;
    margin: 0.5rem 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.balance-subtitle {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
}

.earning-section, .visa-section, .store-section, .transactions-section, .achievements-section {
    margin-bottom: 3rem;
}

.earning-section h3, .visa-section h3, .store-section h3, .transactions-section h3, .achievements-section h3 {
    color: #071F35;
    font-size: 1.8rem;
    margin-bottom: 1.5rem;
    font-weight: bold;
    text-align: center;
}

.activities-grid, .rewards-grid, .achievements-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.activity-card, .reward-item, .achievement-item {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    border: 2px solid #f0f0f0;
    transition: all 0.3s ease;
    cursor: pointer;
}

.activity-card:hover, .reward-item:hover, .achievement-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(7, 31, 53, 0.2);
    border-color: #071F35;
}

.activity-card {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.activity-icon, .reward-icon, .achievement-icon {
    font-size: 2.5rem;
    flex-shrink: 0;
}

.activity-info, .reward-info, .achievement-info {
    flex: 1;
}

.activity-info h4, .reward-info h4, .achievement-info h4 {
    margin: 0 0 0.5rem 0;
    color: #071F35;
    font-weight: bold;
    font-size: 1.2rem;
}

.activity-info p, .reward-info p, .achievement-info p {
    margin: 0 0 0.5rem 0;
    color: #666;
    line-height: 1.4;
}

.reward-amount, .reward-cost {
    font-weight: bold;
    color: #071F35;
    font-size: 1.1rem;
}

.reward-item {
    text-align: center;
}

.redeem-btn {
    background: #071F35;
    color: white;
    border: none;
    border-radius: 25px;
    padding: 0.75rem 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 1rem;
    width: 100%;
}

.redeem-btn:hover {
    background: #0A2A47;
    transform: translateY(-2px);
}

.redeem-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
}

.transactions-list {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.transaction-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.transaction-item:last-child {
    border-bottom: none;
}

.transaction-icon {
    font-size: 1.5rem;
}

.transaction-info {
    flex: 1;
}

.transaction-desc {
    display: block;
    font-weight: bold;
    color: #333;
}

.transaction-time {
    display: block;
    font-size: 0.9rem;
    color: #666;
}

.transaction-amount {
    font-weight: bold;
    font-size: 1.1rem;
}

.transaction-amount.positive {
    color: #28a745;
}

.transaction-amount.negative {
    color: #dc3545;
}

.achievement-item.locked {
    opacity: 0.6;
    background: #f8f9fa;
}

.achievement-item.unlocked {
    background: linear-gradient(135deg, #d4edda 0%, #c3e6cb 100%);
    border-color: #28a745;
}

.achievement-progress {
    font-size: 0.9rem;
    color: #666;
    font-weight: bold;
}

.achievement-item.unlocked .achievement-progress {
    color: #155724;
}

/* Fruit Animation for Rewards */
.fruit-earned {
    position: fixed;
    font-size: 2rem;
    z-index: 9999;
    pointer-events: none;
    animation: fruitFloat 2s ease-out forwards;
}

@keyframes fruitFloat {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1) rotate(0deg);
    }
    50% {
        transform: translateY(-50px) scale(1.2) rotate(180deg);
    }
    100% {
        opacity: 0;
        transform: translateY(-100px) scale(1.5) rotate(360deg);
    }
}

/* VISA Gift Cards Styling */
.visa-banner {
    background: linear-gradient(135deg, #1a1f71 0%, #0f4c75 100%);
    color: white;
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 2rem;
    box-shadow: 0 10px 30px rgba(26, 31, 113, 0.3);
}

.visa-logo {
    font-size: 3rem;
    font-weight: bold;
    font-family: 'Arial', sans-serif;
    letter-spacing: 0.2em;
    color: #ffffff;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.visa-message h4 {
    margin: 0 0 0.5rem 0;
    font-size: 1.5rem;
    font-weight: bold;
}

.visa-message p {
    margin: 0;
    opacity: 0.9;
    font-size: 1.1rem;
    line-height: 1.4;
}

.visa-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.visa-card-item {
    background: white;
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    border: 2px solid #f0f0f0;
    transition: all 0.3s ease;
    overflow: hidden;
    position: relative;
}

.visa-card-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px rgba(26, 31, 113, 0.2);
    border-color: #1a1f71;
}

.visa-card-visual {
    background: linear-gradient(135deg, #1a1f71 0%, #0f4c75 100%);
    color: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    position: relative;
    min-height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.visa-card-visual.premium {
    background: linear-gradient(135deg, #d4af37 0%, #ffd700 100%);
    color: #000;
}

.card-chip {
    font-size: 1.5rem;
    align-self: flex-start;
}

.card-amount {
    font-size: 2.5rem;
    font-weight: bold;
    text-align: center;
    margin: 0.5rem 0;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.card-brand {
    font-size: 1rem;
    font-weight: bold;
    text-align: right;
    letter-spacing: 0.1em;
}

.premium-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.2);
    padding: 0.25rem 0.5rem;
    border-radius: 15px;
    font-size: 0.8rem;
    font-weight: bold;
}

.visa-card-info h4 {
    color: #071F35;
    font-size: 1.3rem;
    margin: 0 0 0.5rem 0;
    font-weight: bold;
}

.visa-card-info p {
    color: #666;
    margin: 0 0 1rem 0;
    line-height: 1.4;
}

.conversion-rate {
    background: #f8f9fa;
    padding: 0.75rem;
    border-radius: 10px;
    text-align: center;
    font-weight: bold;
    color: #071F35;
    margin-bottom: 1rem;
    border: 2px solid #e9ecef;
}

.visa-redeem-btn {
    width: 100%;
    background: #1a1f71;
    color: white;
    border: none;
    border-radius: 25px;
    padding: 1rem;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.visa-redeem-btn:hover {
    background: #0f4c75;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(26, 31, 113, 0.4);
}

.visa-redeem-btn.premium {
    background: linear-gradient(135deg, #d4af37 0%, #ffd700 100%);
    color: #000;
}

.visa-redeem-btn.premium:hover {
    background: linear-gradient(135deg, #b8941f 0%, #e6c200 100%);
}

.visa-redeem-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.visa-info-section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 2rem;
}

.visa-benefits, .visa-terms {
    background: white;
    border-radius: 15px;
    padding: 1.5rem;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.visa-benefits h4, .visa-terms h4 {
    color: #071F35;
    margin: 0 0 1rem 0;
    font-size: 1.2rem;
    font-weight: bold;
}

.visa-benefits ul, .visa-terms ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.visa-benefits li, .visa-terms li {
    padding: 0.5rem 0;
    border-bottom: 1px solid #f0f0f0;
    line-height: 1.4;
}

.visa-benefits li:last-child, .visa-terms li:last-child {
    border-bottom: none;
}

.visa-benefits li strong {
    color: #1a1f71;
}

/* VISA Card Animation */
.visa-processing {
    position: relative;
}

.visa-processing::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    animation: visaShimmer 2s infinite;
}

@keyframes visaShimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

/* VISA Success Modal */
.visa-success-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    padding: 2rem;
}

.visa-success-content {
    background: white;
    border-radius: 20px;
    padding: 2rem;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.5s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.visa-success-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 2px solid #f0f0f0;
}

.visa-success-header h2 {
    color: #071F35;
    margin: 0;
    font-size: 1.5rem;
}

.visa-close-btn {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.visa-close-btn:hover {
    background: #f0f0f0;
    color: #333;
}

.visa-card-display {
    margin: 1.5rem 0;
    display: flex;
    justify-content: center;
}

.virtual-card {
    background: linear-gradient(135deg, #1a1f71 0%, #0f4c75 100%);
    color: white;
    border-radius: 15px;
    padding: 1.5rem;
    width: 300px;
    height: 180px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 0 10px 30px rgba(26, 31, 113, 0.3);
}

.card-top {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.card-chip {
    font-size: 1.5rem;
}

.card-logo {
    font-size: 1.2rem;
    font-weight: bold;
    letter-spacing: 0.1em;
}

.card-number {
    font-size: 1.2rem;
    font-weight: bold;
    letter-spacing: 0.2em;
    text-align: center;
    margin: 1rem 0;
}

.card-details {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
}

.card-amount {
    font-size: 1.5rem;
    font-weight: bold;
}

.card-expiry {
    font-size: 0.9rem;
    opacity: 0.9;
}

.visa-instructions {
    margin: 1.5rem 0;
}

.visa-instructions h3 {
    color: #071F35;
    margin: 0 0 1rem 0;
    font-size: 1.2rem;
}

.visa-instructions ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.visa-instructions li {
    padding: 0.5rem 0;
    color: #666;
    line-height: 1.4;
}

.visa-actions {
    display: flex;
    gap: 1rem;
    margin-top: 1.5rem;
}

.visa-btn {
    flex: 1;
    padding: 1rem;
    border: none;
    border-radius: 10px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
}

.visa-btn.primary {
    background: #1a1f71;
    color: white;
}

.visa-btn.primary:hover {
    background: #0f4c75;
    transform: translateY(-2px);
}

.visa-btn.secondary {
    background: #f0f0f0;
    color: #333;
}

.visa-btn.secondary:hover {
    background: #e0e0e0;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .visa-banner {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .visa-logo {
        font-size: 2.5rem;
    }
    
    .visa-cards-grid {
        grid-template-columns: 1fr;
    }
    
    .visa-info-section {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .balance-header {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .activities-grid, .rewards-grid, .achievements-grid {
        grid-template-columns: 1fr;
    }
    
    .activity-card {
        flex-direction: column;
        text-align: center;
        gap: 1rem;
    }
    
    .balance-amount {
        font-size: 2.5rem;
    }
    
    .coin-icon {
        font-size: 3rem;
    }
}

/* Print Styles */
@media print {
    .navbar,
    .notes-controls,
    .profile-actions,
    .flashcard-controls {
        display: none;
    }
    
    .content-section {
        box-shadow: none;
        border: 1px solid #ccc;
    }
}