:root {
    --accent1: #e91e63;
    --accent2: #ff4081;
}

body {
    font-family: 'Poppins', sans-serif;
    margin: 0;
    background: #f9f9fb;
    color: #333;
    text-align: center;
    padding-bottom: 80px;
}

header {
    background: linear-gradient(90deg, var(--accent1), var(--accent2));
    color: white;
    padding: 16px 20px;
    font-size: 1.4em;
    font-weight: 600;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header a.home-link {
    color: #fff;
    text-decoration: none;
    font-size: .85rem;
    font-weight: 600;
    opacity: .9;
    transition: opacity .3s ease;
}

header a.home-link:hover {
    opacity: 1;
    text-decoration: underline;
}

h1 {
    margin: 48px 0 24px;
    color: var(--accent1);
    font-size: 2.1rem;
}

.cta-group {
    margin-bottom: 48px;
}

.btn {
    display: inline-block;
    padding: 14px 32px;
    margin: 10px;
    border-radius: 999px;
    text-decoration: none;
    color: white;
    font-weight: 600;
    font-size: 1.05rem;
    transition: transform 0.25s ease, box-shadow 0.25s ease;
    background: linear-gradient(135deg, var(--accent1), var(--accent2));
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
}
.btn:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 8px 20px rgba(0,0,0,.25), 0 0 12px var(--accent1), 0 0 24px var(--accent2);
}

section {
    max-width: 800px;
    margin: 0 auto 60px;
    padding: 32px 24px;
    background: rgba(255,255,255,.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,.08);
    text-align: left;
}

section h2 {
    margin-top: 0;
    color: var(--accent1);
}

.coming-soon {
    font-style: italic;
    color: #777;
    margin-top: 12px;
}

.mocktest-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(clamp(120px, 20vw, 150px), 1fr));
    gap: 8px;
    margin-top: 8px;
}

.studymaterial-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(clamp(120px, 20vw, 150px), 1fr));
    gap: 8px;
    margin-top: 8px;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.section-row {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 24px;
    max-width: 1000px;
    margin: 0 auto 60px;
    padding: 0 24px;
}

.section-row section {
    flex: 1 1 400px;
    max-width: 480px;
    background: rgba(255,255,255,.75);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0,0,0,.08);
    padding: 32px 24px;
    text-align: left;
}

/* ── Nav & toggle button ── */
nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 16px;
}

nav ul li a {
    color: #fff;
    text-decoration: none;
}

.theme-toggle {
    background: transparent;
    border: 1.5px solid rgba(255,255,255,0.5);
    border-radius: 20px;
    cursor: pointer;
    font-size: 16px;
    padding: 4px 10px;
    line-height: 1;
    color: #fff;
    vertical-align: middle;
}
.theme-toggle:hover {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,255,255,0.85);
}

/* ── Global transition ── */
*, *::before, *::after {
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

/* ================================================================
   DARK MODE
   ================================================================ */

/* Override CSS variables — fixes buttons, h1, h2 automatically
   since they all use var(--accent1/2). Pink shifts to deep rose. */
[data-theme="dark"] {
    --accent1: #880e4f;
    --accent2: #ad1457;
}

[data-theme="dark"] body {
    background: #121212;
    color: #e0e0e0;
}

/* Headings — override to readable light tones */
[data-theme="dark"] h1 {
    color: #f48fb1;
}
[data-theme="dark"] h2,
[data-theme="dark"] section h2 {
    color: #f06292;
}
[data-theme="dark"] h3 {
    color: #f06292;
}

[data-theme="dark"] p {
    color: #cccccc;
}

/* Sections / cards */
[data-theme="dark"] section,
[data-theme="dark"] .section-row section {
    background: rgba(30,30,30,0.95);
    box-shadow: 0 4px 20px rgba(0,0,0,0.4);
    border: 1px solid #333;
}

/* Buttons — keep gradient readable; force white text */
[data-theme="dark"] .btn {
    color: #fff !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.4);
    text-shadow: 0 1px 3px rgba(0,0,0,0.35);
}
[data-theme="dark"] .btn:hover {
    color: #fff !important;
    box-shadow: 0 8px 20px rgba(0,0,0,0.5), 0 0 14px var(--accent1), 0 0 28px var(--accent2);
}

/* Coming soon */
[data-theme="dark"] .coming-soon {
    color: #888;
}

/* Footer */
[data-theme="dark"] .footer,
[data-theme="dark"] footer {
    background-color: #1a1a1a;
    color: #aaaaaa;
}