:root {
    --bg-color: #F5F5F7;
    --card-bg: #FFFFFF;
    --text-primary: #1D1D1F;
    --text-secondary: #86868B;
    --accent-color: #0066CC;
    --accent-hover: #004499;
    --border-color: #D2D2D7;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --radius-lg: 18px;
    --radius-md: 12px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-family);
    background-color: var(--bg-color);
    color: var(--text-primary);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

/* Navbar */
.navbar {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1024px;
    margin: 0 auto;
    padding: 0 24px;
    height: 52px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--text-primary);
    text-decoration: none;
    letter-spacing: -0.01em;
}

.nav-links {
    display: flex;
    gap: 8px;
}

.nav-btn {
    background: none;
    border: none;
    padding: 6px 14px;
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    border-radius: 99px;
    transition: all 0.2s ease;
}

.nav-btn:hover {
    color: var(--text-primary);
    background: rgba(0, 0, 0, 0.05);
}

.nav-btn.active {
    background: var(--text-primary);
    color: #fff;
}

/* Layout */
.container {
    max-width: 1024px;
    margin: 0 auto;
    padding: 40px 24px 80px;
    min-height: calc(100vh - 150px);
}

.view.hidden {
    display: none;
}

.view {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Headers */
.section-header {
    text-align: center;
    margin-bottom: 40px;
}

.section-header h1 {
    font-size: 40px;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
}

.section-header p {
    font-size: 19px;
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 30px;
}

/* Search & Filter */
.search-bar {
    max-width: 400px;
    margin: 0 auto;
    position: relative;
}

.search-input {
    width: 100%;
}

#search-input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    font-size: 15px;
    background: var(--card-bg);
    transition: border-color 0.2s, box-shadow 0.2s;
    outline: none;
}

#search-input:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}

.search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
    pointer-events: none;
}

.filter-tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin-bottom: 32px;
}

.filter-btn {
    border: none;
    background: none;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 6px 0;
    position: relative;
    transition: color 0.2s;
}

.filter-btn:hover {
    color: var(--text-primary);
}

.filter-btn.active {
    color: var(--accent-color);
}

.filter-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: var(--accent-color);
}

/* Grid */
.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

/* Cards */
.card {
    background: var(--card-bg);
    border-radius: var(--radius-lg);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s, box-shadow 0.2s;
    border: 1px solid rgba(0, 0, 0, 0.02);
}

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

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
}

.card-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
}

.badge {
    font-size: 11px;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 6px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.badge-excel {
    background: rgba(33, 163, 102, 0.1);
    color: #107C41;
}

.badge-db {
    background: rgba(0, 102, 204, 0.1);
    color: #0066CC;
}

.code-block {
    background: #F5F7FA;
    padding: 12px;
    border-radius: 8px;
    font-family: 'SF Mono', SFMono-Regular, ui-monospace, monospace;
    font-size: 13px;
    color: #333;
    margin-bottom: 12px;
    overflow-x: auto;
}

.card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.card-footer {
    padding-top: 16px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    font-size: 13px;
}

.example-label {
    font-weight: 600;
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-secondary);
    margin-bottom: 4px;
    display: block;
}

.example-text {
    color: var(--text-primary);
    font-family: 'SF Mono', SFMono-Regular, monospace;
}

/* Quiz Styles */
.quiz-card {
    background: var(--card-bg);
    max-width: 600px;
    margin: 0 auto;
    border-radius: 20px;
    padding: 40px;
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.primary-btn {
    background: var(--accent-color);
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 99px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.2s;
    margin-top: 24px;
}

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

.options-grid {
    display: grid;
    gap: 12px;
    margin-top: 32px;
}

.option-btn {
    background: var(--bg-color);
    border: 1px solid var(--border-color);
    padding: 16px;
    border-radius: 12px;
    text-align: left;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 15px;
    font-weight: 500;
}

.option-btn:hover {
    background: #EAEAEA;
}

.option-btn.correct {
    background: #E6F4EA;
    border-color: #34A853;
    color: #137333;
}

.option-btn.wrong {
    background: #FCE8E6;
    border-color: #D93025;
    color: #C5221F;
}

/* Footer */
.site-footer {
    background: #F5F5F7;
    border-top: 1px solid #D2D2D7;
    padding: 40px 0;
    font-size: 12px;
    color: var(--text-secondary);
    text-align: center;
}

.footer-content {
    max-width: 1024px;
    margin: 0 auto;
    padding: 0 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-links {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.footer-links a {
    color: var(--text-secondary);
    text-decoration: none;
}

.footer-links a:hover {
    text-decoration: underline;
}

@media (max-width: 768px) {
    .section-header h1 {
        font-size: 32px;
    }

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

/* styles.css - Apple-Inspired Clean White Design */

:root {
    --bg: #ffffff;
    --panel: #f5f5f7;
    --text: #1d1d1f;
    --muted: #6e6e73;
    --brand: #0071e3;
    --accent: #06c;
    --danger: #e24444;
    --border: #d2d2d7;
    --hover-bg: #fafafa;
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", system-ui, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    line-height: 1.47059;
    font-weight: 400;
    letter-spacing: -0.022em;
}

/* Header & Unified Navigation Style */
.site-header {
    max-width: 1200px;
    margin: 0 auto;
    /* Reduced vertical padding to make header shorter */
    padding: 10px 16px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: saturate(180%) blur(25px);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 1px solid var(--border);
}

nav {
    display: flex;
    background: rgba(0, 0, 0, 0.05);
    padding: 4px;
    border-radius: 980px;
    gap: 4px;
    /* FIX: Allow buttons to wrap naturally on mobile without scrolling */
    flex-wrap: wrap;
    justify-content: center;
}

nav a {
    color: var(--text);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    padding: 8px 20px;
    border-radius: 980px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    /* Keep buttons same size */
    white-space: nowrap;
}

nav a:hover {
    background: #ffffff;
    color: var(--brand);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

nav a[aria-current="page"] {
    background: transparent;
    color: var(--text);
    font-weight: 600;
}

/* Main Layout */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 60px 16px;
    /* FIX: Ensures elements flow vertically to prevent Back Button overlap */
    display: flex;
    flex-direction: column;
}

.two-column-layout {
    display: flex;
    gap: 48px;
    align-items: flex-start;
    justify-content: stretch;
}

.column {
    flex: 1 1 0;
    min-width: 0;
}

/* Panel - Apple Card Style */
.panel {
    background: var(--bg);
    border-radius: 18px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07), 0 0 0 1px rgba(0, 0, 0, 0.04);
    padding: 48px 40px;
    margin: 0 0 24px 0;
    transition: box-shadow 0.3s ease, transform 0.3s ease;
}

.panel:hover {
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.1), 0 0 0 1px rgba(0, 0, 0, 0.04);
    transform: translateY(-2px);
}

.panel h2 {
    font-size: 32px;
    font-weight: 600;
    line-height: 1.125;
    letter-spacing: 0.004em;
    margin: 0 0 24px 0;
    color: var(--text);
}

.panel h3 {
    font-size: 21px;
    font-weight: 600;
    line-height: 1.381;
    letter-spacing: 0.011em;
    margin: 24px 0 12px 0;
    color: var(--text);
}

/* Lists */
.pdf-list, .scope-list, .resource-list, .counts {
    list-style: none;
    padding: 0;
    margin: 0;
}

.pdf-list li, .scope-list li {
    margin: 18px 0;
    color: var(--text);
    font-size: 17px;
    line-height: 1.47059;
    font-weight: 400;
}
/* Styling for the protected label */
.lock-icon {
    background-color: #fff3cd; /* Light yellow warning color */
    color: #856404;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    margin-left: 10px;
    border: 1px solid #ffeeba;
    display: inline-flex;
    align-items: center;
}

/* Optional: change the hover effect for protected items */
.resource-list li:has(.lock-icon) {
    border-left: 4px solid #ffc107;
}
/* Resource Items - Clean Card Style */
.resource-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    margin: 12px 0;
    border-radius: 12px;
    background: var(--panel);
    border: 1px solid var(--border);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.resource-item:hover {
    background: var(--hover-bg);
    border-color: var(--brand);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    transform: translateY(-1px);
}

.resource-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.resource-title {
    font-weight: 600;
    font-size: 17px;
    color: var(--text);
    line-height: 1.47059;
}

.resource-date {
    font-size: 14px;
    color: var(--muted);
    font-weight: 400;
}

.resource-actions {
    display: flex;
    gap: 12px;
    flex-shrink: 0;
}

/* Buttons - Apple Style */
.btn.main-btn {
    display: block;
    width: 100%;
    text-align: center;
    background: var(--brand);
    color: #ffffff;
    padding: 16px 24px;
    border-radius: 980px;
    border: none;
    font-weight: 400;
    font-size: 17px;
    margin-top: 32px;
    text-decoration: none;
    letter-spacing: -0.022em;
    transition: all 0.3s ease;
    box-sizing: border-box;
    cursor: pointer;
}

.btn.main-btn:hover {
    background: #0077ed;
    box-shadow: 0 4px 12px rgba(0, 113, 227, 0.25);
    transform: scale(1.02);
}

.btn-small {
    background: transparent;
    color: var(--brand);
    border: 1px solid var(--border);
    padding: 8px 16px;
    border-radius: 980px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
}

.btn-small:hover {
    background: var(--panel);
    border-color: var(--brand);
    transform: translateY(-1px);
}

/* Back Button specifically */
.btn-small.back-btn {
    margin-bottom: 30px; /* Space added here to stop card overlap */
    align-self: flex-start; /* Keeps it to the left */
}

/* Search Bar */
.searchbar {
    margin-bottom: 24px;
}

.searchbar input[type="search"] {
    width: 100%;
    padding: 12px 16px;
    border-radius: 10px;
    border: 1px solid var(--border);
    background: var(--panel);
    color: var(--text);
    outline: none;
    font-size: 17px;
    font-family: inherit;
    transition: all 0.3s ease;
}

.searchbar input[type="search"]::placeholder {
    color: var(--muted);
}

.searchbar input[type="search"]:focus {
    border-color: var(--brand);
    box-shadow: 0 0 0 4px rgba(0, 113, 227, 0.1);
    background: var(--bg);
}

/* Counts */
.counts li {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 17px;
    color: var(--text);
}

.counts li:last-child {
    border-bottom: none;
}

/* Cookie Overlay */
.cookie-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 10000;
}

.cookie-card {
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(30px) saturate(190%);
    -webkit-backdrop-filter: blur(30px) saturate(190%);
    width: 90%;
    max-width: 400px;
    padding: 40px 32px;
    border-radius: 32px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.cookie-card h2 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 12px;
    letter-spacing: -0.02em;
    color: var(--text);
}

.cookie-card p {
    font-size: 15px;
    color: var(--muted);
    line-height: 1.5;
    margin-bottom: 32px;
}

.cookie-buttons-stack {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-full {
    width: 100%;
    padding: 16px;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s ease;
}

.btn-full.primary {
    background: var(--brand);
    color: white;
}

.btn-full.secondary {
    background: rgba(0, 0, 0, 0.05);
    color: var(--text);
}

/* Responsive: Stack on Mobile */
@media (max-width: 900px) {
    .two-column-layout {
        flex-direction: column;
        gap: 24px;
    }

    .panel {
        margin-bottom: 24px;
        padding: 32px 24px;
    }

    main {
        padding: 40px 16px;
    }

    .panel h2 {
        font-size: 28px;
    }

    /* Fixed site header layout for mobile */
    .site-header {
        flex-direction: column;
        gap: 12px;
    }
}

@media (max-width: 768px) {
    .resource-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .resource-actions {
        width: 100%;
        justify-content: flex-end;
    }
}

/* Footer Styles */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 40px 16px;
    margin-top: 60px;
    background: var(--bg);
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--muted);
    font-size: 12px;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
        gap: 16px;
        text-align: center;
    }
}

.footer-nav {
    display: flex;
    gap: 20px;
}

.footer-nav a {
    color: var(--muted);
    text-decoration: none;
    font-weight: 400;
}