/* ===================================
   Global Styles & Reset
   =================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    /* MLTOONS Professional Color Palette */
    --primary-blue: #1263c7;
    --primary-blue-hover: #045cb4;
    --primary-blue-dark: #004ead;
    --accent-cyan: #00a0e6;
    --accent-magenta: #dc4496;
    --warm-brown: #a96d19;

    /* Background Colors */
    --bg-light: #F5F5F5;
    --bg-white: #FFFFFF;
    --bg-gradient: linear-gradient(135deg, #1263c7 0%, #045cb4 100%);

    /* Text Colors */
    --text-dark: #1c232f;
    --text-medium: #3e4851;
    --text-light: #718096;

    /* Accent Colors */
    --success: #48BB78;
    --warning: #ECC94B;
    --danger: #F56565;

    /* Shadows */
    --shadow-sm: 0px 1px 2px rgba(0,0,0,0.05);
    --shadow-md: 0 2px 6px rgba(0,0,0,0.08);
    --shadow-lg: 0 4px 12px rgba(0,0,0,0.1);
    --shadow-xl: 0 8px 20px rgba(0,0,0,0.12);

    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 30px;
}

/* Custom Fonts */
@font-face {
    font-family: 'Milk Kids';
    src: url('../assets/fonts/Milk Kids.otf') format('opentype');
    font-weight: normal;
    font-style: normal;
}

body {
    font-family: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    background: var(--bg-white);
    color: var(--text-dark);
    line-height: 1.65;
    overflow-x: hidden;
    font-size: 16px;
    font-weight: 400;
}

/* ===================================
   Navigation Bar
   =================================== */
.navbar {
    background: #0089c6;
    padding: 1rem 2.5rem;
    box-shadow: 0 4px 20px rgba(0, 137, 198, 0.3);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

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

.logo h1 {
    color: #FFFFFF;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-size: 1.8rem;
    font-weight: 700;
    text-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 0.5rem;
}

.nav-menu li a {
    color: #FFFFFF;
    text-decoration: none;
    padding: 0.6rem 1.2rem;
    border-radius: var(--radius-xl);
    font-weight: 500;
    font-size: 1rem;
    transition: all 0.3s ease;
    display: block;
}

.nav-menu li a:hover,
.nav-menu li a.active {
    background: rgba(255, 255, 255, 0.25);
    color: #FFFFFF;
    transform: scale(1.05);
}

.menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background: var(--primary-blue);
    margin: 3px 0;
    border-radius: 3px;
    transition: 0.3s;
}

/* ===================================
   Hero Section
   =================================== */
.hero {
    background: var(--bg-gradient);
    padding: 5rem 2.5rem;
    text-align: center;
    position: relative;
    overflow: hidden;
    min-height: 550px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.hero-title {
    font-size: 3rem;
    color: white;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: none;
    animation: none;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.3rem;
    color: white;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    font-weight: 400;
}

.hero-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

.hero-animation {
    position: absolute;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    overflow: hidden;
    z-index: 1;
}

.music-note {
    position: absolute;
    font-size: 3rem;
    color: rgba(255, 255, 255, 0.3);
    animation: float 3s ease-in-out infinite;
}

.note1 { top: 20%; left: 10%; animation-delay: 0s; }
.note2 { top: 60%; right: 15%; animation-delay: 1s; }
.note3 { top: 40%; left: 20%; animation-delay: 2s; }
.note4 { top: 70%; right: 25%; animation-delay: 1.5s; }

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

@keyframes bounceIn {
    0% { transform: scale(0.3); opacity: 0; }
    50% { transform: scale(1.05); }
    70% { transform: scale(0.9); }
    100% { transform: scale(1); opacity: 1; }
}

/* ===================================
   Buttons
   =================================== */
.btn {
    padding: 0.75rem 1.8rem;
    font-size: 1rem;
    font-weight: 600;
    border: 2px solid transparent;
    border-radius: var(--radius-sm);
    cursor: pointer;
    text-decoration: none;
    display: inline-block;
    transition: all 0.3s ease;
    box-shadow: none;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn:active {
    transform: translateY(0);
}

.btn-primary {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
}

.btn-primary:hover {
    background: var(--primary-blue-hover);
    border-color: var(--primary-blue-hover);
}

.btn-secondary {
    background: transparent;
    color: var(--primary-blue);
    border-color: var(--primary-blue);
}

.btn-secondary:hover {
    background: var(--primary-blue);
    color: white;
}

.btn-large {
    padding: 1rem 2.5rem;
    font-size: 1.1rem;
}

.btn-play {
    background: var(--primary-blue);
    color: white;
    width: 100%;
    margin-top: 1rem;
}

.btn-play:hover {
    background: var(--primary-blue-hover);
}

.btn-activity {
    background: var(--primary-blue-light);
    color: white;
}

.btn-activity:hover {
    background: var(--primary-blue);
}

/* ===================================
   Sections
   =================================== */
.features,
.topics,
.cta {
    padding: 4rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    text-align: center;
    font-size: 2.2rem;
    color: var(--text-dark);
    margin-bottom: 3rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--shadow-xl);
}

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

.feature-card h3 {
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 1rem;
    font-weight: 600;
}

.feature-card p {
    color: var(--text-medium);
    font-size: 1.1rem;
}

/* Topics Grid */
.topics {
    background: white;
    border-radius: var(--radius-xl);
    margin: 2rem auto;
}

.topics-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.topic-badge {
    background: var(--bg-light);
    color: var(--text-dark);
    padding: 1.2rem;
    border-radius: var(--radius-md);
    font-size: 1.1rem;
    font-weight: 600;
    text-align: center;
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.topic-badge:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-blue);
    background: white;
}

/* Call to Action */
.cta {
    background: var(--bg-gradient);
    border-radius: var(--radius-lg);
    text-align: center;
    color: white;
}

.cta-content h2 {
    font-size: 2.2rem;
    margin-bottom: 1rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.cta-content p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
}

/* ===================================
   Page Header
   =================================== */
.page-header {
    background: var(--bg-gradient);
    padding: 3rem 2.5rem;
    text-align: center;
    color: white;
}

.page-header h1 {
    font-size: 2.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.95;
    font-weight: 400;
}

/* ===================================
   Songs Page
   =================================== */
.songs-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.song-category {
    margin-bottom: 3rem;
}

.category-title {
    font-size: 1.8rem;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.songs-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.song-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.song-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.song-icon {
    font-size: 3.5rem;
    margin-bottom: 1rem;
}

.song-card h3 {
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.song-card p {
    color: var(--text-medium);
    margin-bottom: 1rem;
}

/* ===================================
   Activities Page
   =================================== */
.activities-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem;
}

.activities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 2rem;
}

.activity-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    transition: all 0.3s ease;
}

.activity-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-xl);
}

.activity-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.activity-icon {
    font-size: 2.5rem;
}

.activity-card h3 {
    font-size: 1.5rem;
    color: var(--text-dark);
}

.activity-card p {
    color: var(--text-medium);
    margin-bottom: 1rem;
    font-size: 1.05rem;
}

.difficulty-level {
    margin-bottom: 1rem;
}

.badge {
    padding: 0.4rem 0.8rem;
    border-radius: var(--radius-sm);
    font-size: 0.9rem;
    font-weight: 600;
}

.badge-easy {
    background: #C6F6D5;
    color: #22543D;
}

.badge-medium {
    background: #FED7AA;
    color: #7C2D12;
}

.badge-hard {
    background: #FED7D7;
    color: #742A2A;
}

/* ===================================
   Progress Page
   =================================== */
.stats-overview {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.stat-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: scale(1.05);
    box-shadow: var(--shadow-lg);
}

.stat-icon {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.stat-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-blue);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.stat-label {
    font-size: 1.1rem;
    color: var(--text-medium);
    margin-top: 0.5rem;
}

.achievements-section,
.topic-progress-section,
.daily-goal-section {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.badges-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
    gap: 2rem;
}

.badge-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: all 0.3s ease;
}

.badge-card.earned {
    border: 3px solid var(--primary-yellow);
}

.badge-card.locked {
    opacity: 0.6;
    filter: grayscale(50%);
}

.badge-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

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

.badge-card h3 {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.badge-card p {
    color: var(--text-medium);
    margin-bottom: 0.5rem;
}

.badge-date {
    font-size: 0.9rem;
    color: var(--primary-green);
    font-weight: 600;
}

.badge-progress {
    font-size: 0.9rem;
    color: var(--primary-blue);
    font-weight: 600;
}

.progress-list {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.progress-item {
    margin-bottom: 2rem;
}

.progress-item:last-child {
    margin-bottom: 0;
}

.progress-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.progress-emoji {
    font-size: 1.5rem;
    margin-right: 0.5rem;
}

.progress-topic {
    flex: 1;
    font-weight: 600;
    color: var(--text-dark);
}

.progress-percentage {
    font-weight: 700;
    color: var(--primary-blue);
}

.progress-bar {
    background: #E2E8F0;
    height: 20px;
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.progress-fill {
    background: var(--primary-blue);
    height: 100%;
    border-radius: var(--radius-lg);
    transition: width 0.5s ease;
}

.daily-goal-card {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
}

.goal-text {
    font-size: 1.4rem;
    color: var(--text-dark);
    margin-bottom: 2rem;
    font-weight: 600;
}

.goal-steps {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.goal-step {
    font-size: 2rem;
}

.goal-status {
    font-size: 1.1rem;
    color: var(--text-medium);
    margin-bottom: 2rem;
}

/* ===================================
   Parents Page
   =================================== */
.parents-section {
    max-width: 1000px;
    margin: 0 auto;
    padding: 3rem 2rem;
}

.parents-section.bg-light {
    background: white;
    border-radius: var(--radius-lg);
    margin: 2rem auto;
    box-shadow: var(--shadow-sm);
}

.parents-content h2 {
    font-size: 2rem;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.parents-content h3 {
    font-size: 1.5rem;
    color: var(--text-dark);
    margin: 1.5rem 0 1rem;
}

.parents-content p {
    font-size: 1.1rem;
    color: var(--text-medium);
    margin-bottom: 1rem;
    line-height: 1.8;
}

.benefits-list {
    list-style: none;
    margin: 1.5rem 0;
}

.benefits-list li {
    font-size: 1.1rem;
    color: var(--text-medium);
    margin-bottom: 1rem;
    padding-left: 2rem;
    position: relative;
}

.how-it-works-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.step-card {
    text-align: center;
}

.step-number {
    width: 50px;
    height: 50px;
    background: var(--bg-gradient);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 1rem;
}

.step-card h3 {
    font-size: 1.3rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.step-card p {
    font-size: 1rem;
    color: var(--text-medium);
}

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

.tip-card {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.tip-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.tip-card h3 {
    font-size: 1.2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.tip-card p {
    font-size: 1rem;
    color: var(--text-medium);
}

.curriculum-list {
    margin-top: 2rem;
}

.curriculum-item {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-md);
    margin-bottom: 1.5rem;
    border-left: 4px solid var(--primary-blue);
}

.curriculum-item h3 {
    font-size: 1.3rem;
    color: var(--primary-blue);
    margin-bottom: 0.5rem;
}

.curriculum-item p {
    font-size: 1rem;
    color: var(--text-medium);
}

.faq-list {
    margin-top: 2rem;
}

.faq-item {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin-bottom: 1.5rem;
}

.faq-item h3 {
    font-size: 1.2rem;
    color: var(--text-dark);
    margin-bottom: 0.5rem;
}

.faq-item p {
    font-size: 1rem;
    color: var(--text-medium);
}

.contact-buttons {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
    flex-wrap: wrap;
}

/* ===================================
   Modal
   =================================== */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    animation: fadeIn 0.3s ease;
}

.modal-content {
    background: white;
    margin: 5% auto;
    padding: 3rem;
    border-radius: var(--radius-lg);
    max-width: 700px;
    position: relative;
    animation: slideIn 0.3s ease;
}

.activity-modal-content {
    max-width: 900px;
}

.close-modal {
    position: absolute;
    right: 1.5rem;
    top: 1.5rem;
    font-size: 2rem;
    font-weight: bold;
    color: var(--text-medium);
    cursor: pointer;
    transition: color 0.3s ease;
}

.close-modal:hover {
    color: var(--text-dark);
}

#songPlayer h2,
#activityGame h2 {
    font-size: 2rem;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
    text-align: center;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.lyrics-display {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
    min-height: 200px;
    font-size: 1.2rem;
    line-height: 2;
    text-align: center;
}

.player-controls {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.game-instructions {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
    text-align: center;
}

.game-area {
    min-height: 300px;
    padding: 2rem;
    background: var(--bg-light);
    border-radius: var(--radius-lg);
    margin-bottom: 2rem;
}

.game-score {
    display: flex;
    justify-content: space-around;
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--text-dark);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

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

/* ===================================
   Footer
   =================================== */
.footer {
    background: var(--text-dark);
    color: white;
    text-align: center;
    padding: 2.5rem;
    margin-top: 4rem;
}

.footer p {
    margin: 0.5rem 0;
    font-size: 0.95rem;
}

.footer a {
    color: var(--accent-warm);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer a:hover {
    color: var(--primary-blue-light);
}

/* ===================================
   Responsive Design
   =================================== */
@media (max-width: 768px) {
    .menu-toggle {
        display: flex;
    }

    .nav-menu {
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--bg-white);
        flex-direction: column;
        padding: 1rem;
        transform: translateY(-100%);
        opacity: 0;
        pointer-events: none;
        transition: all 0.3s ease;
        box-shadow: var(--shadow-md);
        border-top: 1px solid #e5e7eb;
    }

    .nav-menu.active {
        transform: translateY(0);
        opacity: 1;
        pointer-events: all;
    }

    .hero-title {
        font-size: 2.5rem;
    }

    .hero-subtitle {
        font-size: 1.2rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .features-grid,
    .songs-grid,
    .activities-grid {
        grid-template-columns: 1fr;
    }

    .hero-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .modal-content {
        margin: 10% 1rem;
        padding: 2rem 1rem;
    }

    .stats-overview {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 1.5rem;
    }

    .hero-title {
        font-size: 2rem;
    }

    .page-header h1 {
        font-size: 2rem;
    }

    .stats-overview {
        grid-template-columns: 1fr;
    }
}

/* ===================================
   Authentication Pages
   =================================== */
.auth-header {
    background: var(--bg-white);
    padding: 1rem 2.5rem;
    box-shadow: var(--shadow-sm);
    border-bottom: 1px solid #e5e7eb;
}

.auth-header .logo h1 {
    color: var(--primary-blue);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
    font-size: 1.8rem;
    text-shadow: none;
}

.auth-section {
    min-height: calc(100vh - 100px);
    padding: 3rem 2rem;
}

.auth-container {
    max-width: 500px;
    margin: 0 auto;
}

.auth-card {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    margin-bottom: 2rem;
}

.auth-title {
    font-size: 2rem;
    color: var(--text-dark);
    text-align: center;
    margin-bottom: 0.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.auth-subtitle {
    text-align: center;
    color: var(--text-medium);
    margin-bottom: 2rem;
}

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

.auth-form label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
}

.auth-form input[type="text"],
.auth-form input[type="email"],
.auth-form input[type="password"],
.auth-form input[type="tel"],
.auth-form input[type="number"],
.auth-form select,
.auth-form textarea {
    width: 100%;
    padding: 0.75rem 1rem;
    border: 1px solid #E2E8F0;
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    height: 40px;
}

.auth-form textarea {
    height: auto;
    min-height: 80px;
}

.auth-form input:focus,
.auth-form select:focus,
.auth-form textarea:focus {
    outline: none;
    border-color: #046BD2;
    box-shadow: 0 0 0 3px rgba(4, 107, 210, 0.1);
}

.auth-form small {
    display: block;
    margin-top: 0.25rem;
    font-size: 0.85rem;
    color: var(--text-light);
}

.form-options {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.checkbox-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
}

.link-text {
    color: var(--primary-blue);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.link-text:hover {
    color: var(--primary-blue-hover);
}

.error-message {
    background: #FED7D7;
    color: #742A2A;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    margin-top: 1rem;
    border-left: 4px solid var(--danger);
}

.success-message {
    background: #C6F6D5;
    color: #22543D;
    padding: 0.75rem 1rem;
    border-radius: var(--radius-sm);
    margin-top: 1rem;
    border-left: 4px solid var(--success);
}

.auth-footer {
    text-align: center;
    margin-top: 2rem;
    color: var(--text-medium);
}

.demo-accounts {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin-top: 2rem;
}

.demo-title {
    font-weight: 600;
    color: var(--text-dark);
    margin-bottom: 1rem;
    text-align: center;
}

.demo-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.demo-account {
    background: white;
    padding: 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    border: 1px solid #E2E8F0;
}

.user-type-cards {
    margin-top: 2rem;
}

.role-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.role-card {
    background: white;
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
    cursor: pointer;
    border: 2px solid #E2E8F0;
    transition: all 0.3s ease;
}

.role-card:hover {
    border-color: var(--primary-blue);
    transform: translateY(-3px);
    box-shadow: var(--shadow-md);
}

.role-icon {
    font-size: 3rem;
    margin-bottom: 0.5rem;
}

.role-card h4 {
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.role-card p {
    font-size: 0.9rem;
    color: var(--text-medium);
}

.role-specific-fields {
    animation: fadeIn 0.3s ease;
}

.signup-benefits {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
}

.signup-benefits h3 {
    text-align: center;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
}

.benefits-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.benefit-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
}

.benefit-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.benefit-item h4 {
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.benefit-item p {
    color: var(--text-medium);
    font-size: 0.9rem;
}

/* ===================================
   Dashboard Styles
   =================================== */
.dashboard-header {
    background: var(--bg-gradient);
    padding: 2rem 2.5rem;
    color: white;
}

.dashboard-header.admin-header {
    background: var(--bg-gradient);
}

.dashboard-header.institution-header {
    background: var(--bg-gradient);
}

.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
}

.dashboard-container h1 {
    font-size: 2.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.dashboard-content {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 0 2rem;
}

.dashboard-section {
    background: white;
    padding: 2rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    margin-bottom: 2rem;
}

.dashboard-section h2 {
    color: var(--primary-blue);
    font-size: 2rem;
    margin-bottom: 1.5rem;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
    font-weight: 700;
}

.dashboard-section h3 {
    color: var(--text-dark);
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

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

.quick-actions {
    margin: 2rem 0;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
}

.recent-activity {
    margin-top: 2rem;
}

.activity-list {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
}

/* Students Grid */
.students-grid,
.teachers-grid,
.classes-grid,
.classrooms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

.student-card,
.teacher-card,
.class-card,
.classroom-card {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    border: 2px solid #E2E8F0;
    transition: all 0.3s ease;
}

.student-card:hover,
.teacher-card:hover,
.class-card:hover,
.classroom-card:hover {
    border-color: var(--primary-blue);
    box-shadow: var(--shadow-md);
}

.student-header,
.teacher-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.student-avatar,
.teacher-avatar {
    width: 60px;
    height: 60px;
    background: var(--bg-gradient);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    font-weight: 700;
}

.student-info h3,
.teacher-info h3 {
    color: var(--text-dark);
    margin-bottom: 0.25rem;
}

.student-info p,
.teacher-info p {
    font-size: 0.9rem;
    color: var(--text-medium);
}

.student-stats {
    display: flex;
    justify-content: space-around;
    padding: 1rem 0;
    border-top: 1px solid #E2E8F0;
    border-bottom: 1px solid #E2E8F0;
    margin: 1rem 0;
}

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

.stat-label {
    display: block;
    font-size: 0.85rem;
    color: var(--text-medium);
}

.stat-value {
    display: block;
    font-weight: 700;
    color: var(--text-dark);
    margin-top: 0.25rem;
}

.student-actions,
.teacher-actions,
.class-actions,
.classroom-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: 1rem;
}

.teacher-details,
.classroom-details {
    margin: 1rem 0;
    font-size: 0.95rem;
}

.teacher-details p,
.classroom-details p {
    margin: 0.5rem 0;
    color: var(--text-medium);
}

/* System Health */
.system-health {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    margin: 2rem 0;
}

.health-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.health-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    background: white;
    border-radius: var(--radius-sm);
}

.health-label {
    font-weight: 600;
    color: var(--text-dark);
}

.health-status.status-active {
    color: var(--success);
    font-weight: 600;
}

.health-value {
    color: var(--text-medium);
    font-weight: 600;
}

/* Users Table */
.users-table-container {
    overflow-x: auto;
    margin-top: 1.5rem;
}

.users-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.users-table thead {
    background: var(--bg-light);
}

.users-table th {
    padding: 1rem;
    text-align: left;
    font-weight: 600;
    color: var(--text-dark);
    border-bottom: 2px solid #E2E8F0;
}

.users-table td {
    padding: 1rem;
    border-bottom: 1px solid #E2E8F0;
}

.users-table tbody tr:hover {
    background: var(--bg-light);
}

.role-badge {
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
}

.role-student { background: #C6F6D5; color: #22543D; }
.role-teacher { background: #BFDBFE; color: #1E3A8A; }
.role-admin { background: #FED7AA; color: #7C2D12; }
.role-institution { background: #DDD6FE; color: #5B21B6; }

.status-badge {
    padding: 0.25rem 0.75rem;
    border-radius: var(--radius-sm);
    font-size: 0.85rem;
    font-weight: 600;
}

.status-active { background: #C6F6D5; color: #22543D; }
.status-inactive { background: #FED7D7; color: #742A2A; }

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    border: none;
    border-radius: var(--radius-sm);
    background: var(--primary-blue);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.btn-small:hover {
    background: var(--primary-blue-hover);
    transform: translateY(-1px);
}

.btn-danger {
    background: var(--danger);
}

.btn-danger:hover {
    background: #C53030;
}

.btn-success {
    background: #38A169;
}

.btn-success:hover {
    background: #2F855A;
}

/* Plan badges */
.plan-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.plan-basic {
    background: #E2E8F0;
    color: #4A5568;
}

.plan-standard {
    background: #BEE3F8;
    color: #2B6CB0;
}

.plan-premium {
    background: #FAF089;
    color: #744210;
}

/* Role badges */
.role-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: capitalize;
}

.role-student {
    background: #FED7E2;
    color: #97266D;
}

.role-teacher {
    background: #FEEBC8;
    color: #C05621;
}

.role-institution {
    background: #C6F6D5;
    color: #276749;
}

.role-admin {
    background: #E9D8FD;
    color: #553C9A;
}

/* License section */
.license-section {
    background: white;
    border-radius: var(--radius-md);
    padding: 1.5rem;
    box-shadow: var(--shadow-card);
}

.license-section h3 {
    color: var(--primary-blue);
    margin-bottom: 1rem;
    font-size: 1.2rem;
}

.licenses-table-container {
    overflow-x: auto;
}

.filter-controls {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.filter-controls select,
.filter-controls input {
    padding: 0.75rem 1rem;
    border: 2px solid #E2E8F0;
    border-radius: var(--radius-sm);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.filter-controls select {
    flex: 0 0 200px;
}

.filter-controls input {
    flex: 1;
}

/* Content Stats */
.content-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.content-card {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
    text-align: center;
}

.content-number {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-blue);
    margin: 1rem 0;
}

/* Analytics */
.analytics-grid,
.reports-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.analytics-card,
.report-card {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
}

.chart-placeholder {
    background: white;
    padding: 3rem;
    border-radius: var(--radius-sm);
    text-align: center;
    color: var(--text-medium);
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Settings */
.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.settings-card {
    background: var(--bg-light);
    padding: 2rem;
    border-radius: var(--radius-lg);
}

.settings-card h3 {
    margin-bottom: 1.5rem;
}

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

.settings-form label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--text-dark);
}

.settings-form input[type="text"],
.settings-form input[type="email"],
.settings-form input[type="number"] {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #E2E8F0;
    border-radius: var(--radius-sm);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

.report-filters {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.report-filters select {
    padding: 0.75rem 1rem;
    border: 2px solid #E2E8F0;
    border-radius: var(--radius-sm);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', sans-serif;
}

/* Performance Overview */
.performance-overview {
    margin-top: 2rem;
}

.performance-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.performance-card {
    background: var(--bg-light);
    padding: 1.5rem;
    border-radius: var(--radius-lg);
    text-align: center;
}

.performance-card h4 {
    color: var(--text-medium);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.performance-value {
    font-size: 2rem;
    font-weight: 700;
    color: var(--primary-blue);
}

/* Responsive - Auth Pages */
@media (max-width: 768px) {
    .auth-card {
        padding: 2rem 1.5rem;
    }

    .demo-grid {
        grid-template-columns: 1fr;
    }

    .role-grid {
        grid-template-columns: 1fr;
    }

    .action-buttons {
        flex-direction: column;
    }

    .action-buttons .btn {
        width: 100%;
    }

    .students-grid,
    .teachers-grid,
    .classes-grid,
    .classrooms-grid {
        grid-template-columns: 1fr;
    }

    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }

    .filter-controls {
        flex-direction: column;
    }

    .filter-controls select,
    .filter-controls input {
        width: 100%;
    }

    .users-table-container {
        overflow-x: scroll;
    }
}

/* ===================================
   Landing Page Styles
   =================================== */
.landing {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem 2rem 2rem;
    background: var(--primary-blue);
}

.landing-container {
    max-width: 1200px;
    text-align: center;
}

.landing-title {
    font-family: 'Milk Kids', 'Bubblegum Sans', cursive;
    font-size: 3.5rem;
    color: white;
    margin-bottom: 0;
    text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.landing-subtitle {
    font-size: 1.5rem;
    color: rgba(255,255,255,0.9);
    margin-bottom: 3rem;
}

.access-section {
    background: var(--primary-blue);
    padding: 2rem 2rem 4rem 2rem;
}

.access-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.access-buttons {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    max-width: 900px;
    margin: 0 auto;
}

.access-card {
    background: white;
    border: 2px solid var(--primary-blue);
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.4),
        0 6px 20px rgba(0, 0, 0, 0.3),
        0 3px 10px rgba(0, 0, 0, 0.2);
    position: relative;
}

.access-card:hover {
    transform: translateY(-10px);
    box-shadow:
        0 20px 50px rgba(0, 0, 0, 0.5),
        0 12px 35px rgba(0, 0, 0, 0.4),
        0 6px 20px rgba(0, 0, 0, 0.3);
    border-color: var(--primary-blue-hover);
}

.access-card-image {
    height: 300px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.student-bg {
    background: linear-gradient(135deg, #E0F2FE 0%, #BAE6FD 100%);
}

.school-bg {
    background: linear-gradient(135deg, #D1FAE5 0%, #A7F3D0 100%);
}

.access-illustration {
    font-size: 4rem;
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
}

.girl-reading {
    animation: float 3s ease-in-out infinite;
}

.cow-character {
    animation: float 3s ease-in-out infinite 0.5s;
}

.classroom-scene {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.chalkboard {
    font-size: 5rem;
}

.animals {
    display: flex;
    gap: 0.5rem;
    font-size: 3rem;
}

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

.access-card-label {
    padding: 1.5rem;
    background: white;
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-blue);
    font-family: 'Bubblegum Sans', cursive;
}

/* Login Modal */
.login-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 10000;
    align-items: center;
    justify-content: center;
}

.login-modal.active {
    display: flex;
}

.login-modal-content {
    background: white;
    border-radius: 20px;
    padding: 3rem;
    max-width: 500px;
    width: 90%;
    position: relative;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
}

.login-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-light);
    transition: color 0.3s;
}

.login-close:hover {
    color: var(--text-dark);
}

.login-title {
    font-family: 'Bubblegum Sans', cursive;
    font-size: 2rem;
    color: var(--text-dark);
    margin-bottom: 2rem;
    text-align: center;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group label {
    font-weight: 600;
    color: var(--text-dark);
    font-size: 1rem;
}

.form-group input {
    padding: 1rem;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus {
    outline: none;
    border-color: var(--primary-blue);
}

/* Responsive */
@media (max-width: 768px) {
    .access-buttons {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .landing-title {
        font-size: 2.5rem;
    }

    .landing-subtitle {
        font-size: 1.2rem;
    }

    .access-card-image {
        height: 250px;
    }

    .access-illustration {
        font-size: 3rem;
    }
}

/* ===================================
   Enhanced Mobile/Tablet Responsive
   =================================== */

/* iPad and Tablet (768px - 1024px) */
@media (max-width: 1024px) and (min-width: 769px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .students-grid,
    .teachers-grid,
    .classes-grid,
    .classrooms-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .dashboard-content {
        padding: 1.5rem;
    }

    .nav-menu li a {
        padding: 0.5rem 0.8rem;
        font-size: 0.9rem;
    }
}

/* Mobile Phones (max-width: 768px) */
@media (max-width: 768px) {
    /* Navigation for dashboards */
    .navbar {
        padding: 0.75rem 1rem;
    }

    .nav-container {
        flex-wrap: wrap;
    }

    .logo img {
        height: 45px !important;
    }

    .nav-menu {
        flex-wrap: wrap;
        justify-content: center;
        gap: 0.25rem;
        margin-top: 0.5rem;
        width: 100%;
    }

    .nav-menu li a {
        padding: 0.4rem 0.6rem;
        font-size: 0.8rem;
    }

    /* Dashboard header */
    .dashboard-header {
        padding: 1.5rem 1rem;
    }

    .dashboard-header h1 {
        font-size: 1.5rem;
    }

    .dashboard-content {
        padding: 1rem;
    }

    /* Stats grid */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .stat-card {
        padding: 1rem;
    }

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

    .stat-number {
        font-size: 1.5rem;
    }

    .stat-label {
        font-size: 0.75rem;
    }

    /* Student/Teacher cards */
    .student-card,
    .teacher-card,
    .class-card,
    .classroom-card {
        padding: 1rem;
    }

    .student-avatar,
    .teacher-avatar {
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }

    .student-info h3,
    .teacher-info h3 {
        font-size: 1rem;
    }

    .student-stats {
        flex-wrap: wrap;
        gap: 0.5rem;
    }

    .stat-item {
        flex: 1 1 30%;
        min-width: 60px;
    }

    .student-actions,
    .teacher-actions,
    .class-actions,
    .classroom-actions {
        flex-direction: column;
    }

    .student-actions .btn,
    .teacher-actions .btn,
    .class-actions .btn,
    .classroom-actions .btn {
        width: 100%;
        padding: 0.6rem;
        font-size: 0.85rem;
    }

    /* Modal improvements */
    .modal-content {
        margin: 5% auto;
        width: 95%;
        max-width: 95%;
        padding: 1.5rem 1rem;
        max-height: 90vh;
        overflow-y: auto;
    }

    .modal-content h2 {
        font-size: 1.3rem;
    }

    /* Performance grid */
    .performance-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.75rem;
    }

    .performance-card {
        padding: 1rem;
    }

    .performance-value {
        font-size: 1.5rem;
    }

    /* Reports grid */
    .reports-grid {
        grid-template-columns: 1fr;
    }

    /* Health grid */
    .health-grid {
        grid-template-columns: 1fr;
    }
}

/* Small phones (max-width: 480px) */
@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr 1fr;
        gap: 0.5rem;
    }

    .stat-card {
        padding: 0.75rem;
    }

    .stat-icon {
        font-size: 1.2rem;
    }

    .stat-number {
        font-size: 1.2rem;
    }

    .dashboard-header h1 {
        font-size: 1.3rem;
    }

    .quick-actions h2,
    .recent-activity h2,
    .dashboard-section h2 {
        font-size: 1.1rem;
    }

    .nav-menu li a {
        padding: 0.35rem 0.5rem;
        font-size: 0.75rem;
    }

    .performance-grid {
        grid-template-columns: 1fr;
    }

    /* Auth pages */
    .auth-card {
        padding: 1.5rem 1rem;
    }

    .auth-title {
        font-size: 1.5rem;
    }

    .demo-account {
        padding: 0.75rem;
        font-size: 0.85rem;
    }
}

/* Touch-friendly improvements for all mobile/tablet */
@media (max-width: 1024px) {
    /* Larger touch targets */
    .btn {
        min-height: 44px;
        padding: 0.75rem 1.5rem;
    }

    .btn-small {
        min-height: 36px;
        padding: 0.5rem 0.75rem;
    }

    /* Form inputs */
    .auth-form input,
    .auth-form select,
    .auth-form textarea {
        min-height: 44px;
        font-size: 16px; /* Prevents iOS zoom on focus */
    }

    /* Role cards touch-friendly */
    .role-card {
        padding: 1.25rem;
    }
}

/* ===================================
   Subscription & Billing Styles
   =================================== */
.subscription-overview {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-top: 1.5rem;
}

.subscription-card,
.usage-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    box-shadow: var(--shadow-md);
    border: 1px solid #e5e7eb;
}

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

.subscription-header h3 {
    margin: 0;
    color: var(--text-dark);
}

.plan-badge {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.4rem 1rem;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
}

.plan-badge.basic {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
}

.plan-badge.standard {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.plan-badge.premium {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
}

.subscription-details {
    margin-bottom: 1.5rem;
}

.subscription-details .detail-item {
    display: flex;
    justify-content: space-between;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.subscription-details .detail-item:last-child {
    border-bottom: none;
}

.subscription-details .label {
    color: var(--text-light);
}

.subscription-details .value {
    font-weight: 600;
    color: var(--text-dark);
}

.subscription-actions {
    display: flex;
    gap: 1rem;
}

.subscription-actions .btn {
    flex: 1;
}

.usage-card h3 {
    margin-bottom: 1.5rem;
    color: var(--text-dark);
}

.usage-item {
    margin-bottom: 1.5rem;
}

.usage-item:last-child {
    margin-bottom: 0;
}

.usage-label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-medium);
    font-weight: 500;
}

.usage-bar {
    height: 12px;
    background: #e5e7eb;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 0.25rem;
}

.usage-fill {
    height: 100%;
    background: #10b981;
    border-radius: 6px;
    transition: width 0.5s ease;
}

.usage-text {
    font-size: 0.85rem;
    color: var(--text-light);
}

@media (max-width: 768px) {
    .subscription-overview {
        grid-template-columns: 1fr;
    }

    .subscription-actions {
        flex-direction: column;
    }
}

/* Button Danger Style */
.btn-danger {
    background: #ef4444 !important;
    color: white !important;
}

.btn-danger:hover {
    background: #dc2626 !important;
}

/* Status styles */
.status-inactive {
    color: #ef4444;
}
