/* ============================================================
   Garden Paper Mart Academy — Shared Stylesheet
   Cambridge A Level Accounting (9706)
   Version 1.0 — 2026

   Colour Palette:
   Primary:      Deep Navy      #0d1b2a
   Secondary:    Royal Blue     #1b3a6b
   Mid tone:     Steel Blue     #2d6a9f
   Accent:       Gold           #c9a84c
   Light accent: Pale Gold      #f5e6c0
   Light bg:     Ice Blue       #f0f4f8
   Dark bg:      Midnight       #06111f
   Success:      Emerald        #2e7d32
   Warning:      Amber          #e65100
   Danger:       Crimson        #b71c1c
   ============================================================ */

/* ── RESET & BASE ───────────────────────────────────────────── */
* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: Georgia, 'Times New Roman', serif;
    background: #f0f4f8;
    color: #1a1a2e;
    line-height: 1.8;
}

/* ── HEADER ─────────────────────────────────────────────────── */
header {
    background: linear-gradient(135deg, #06111f 0%, #0d1b2a 50%, #1b3a6b 100%);
    color: white;
    padding: 24px 30px;
    border-bottom: 4px solid #c9a84c;
}
.breadcrumb { font-size: 13px; margin-bottom: 8px; }
.breadcrumb a { color: #9bb8d4; text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; color: white; }
header h1 { font-size: 27px; font-weight: bold; letter-spacing: 0.5px; }
header p.subtitle { color: #9bb8d4; font-size: 14px; margin-top: 6px; }

/* ── MAIN CONTAINER ─────────────────────────────────────────── */
.container { max-width: 920px; margin: 30px auto; padding: 0 20px 60px; }

/* ── SECTIONS ───────────────────────────────────────────────── */
section {
    background: white;
    border-radius: 8px;
    padding: 24px 28px;
    margin-bottom: 24px;
    box-shadow: 0 1px 6px rgba(13,27,42,0.10);
    border-top: 3px solid #1b3a6b;
}

/* ── HEADINGS ───────────────────────────────────────────────── */
h2 {
    color: #0d1b2a;
    font-size: 20px;
    margin-bottom: 14px;
    border-bottom: 2px solid #c5d8ec;
    padding-bottom: 8px;
}
h3 { color: #1b3a6b; font-size: 17px; margin: 18px 0 10px; }
h4 { color: #0d1b2a; margin-bottom: 6px; }

/* ── TYPOGRAPHY ─────────────────────────────────────────────── */
p  { margin-bottom: 12px; }
ul, ol { margin: 10px 0 12px 22px; }
li { margin-bottom: 6px; }
strong { color: #0d1b2a; }

/* ── TABLES ─────────────────────────────────────────────────── */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 14px;
    font-size: 15px;
}
th {
    background: #1b3a6b;
    color: white;
    padding: 10px 14px;
    text-align: left;
    border: 1px solid #2d6a9f;
}
td {
    padding: 10px 14px;
    border: 1px solid #c5d8ec;
    vertical-align: top;
}
tr:nth-child(even) td { background: #eaf0f8; }

/* ── CONTENT TABLE (explanatory / comparison tables) ────────────
   Use for: feature comparisons, terminology tables, definition
   tables, difference tables. Uses Georgia for readability.
   Do NOT use Courier New for text-heavy comparison tables.   */
.content-table {
    width: 100%;
    border-collapse: collapse;
    margin: 14px 0;
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 14px;
}
.content-table th {
    background: #1b3a6b;
    color: white;
    padding: 10px 14px;
    text-align: left;
    border: 1px solid #2d6a9f;
    font-size: 14px;
}
.content-table td {
    padding: 10px 14px;
    border: 1px solid #c5d8ec;
    vertical-align: top;
    line-height: 1.7;
}
.content-table tr:nth-child(even) td { background: #eaf0f8; }
.content-table .feature-col {
    font-weight: bold;
    color: #0d1b2a;
    background: #e8f0f8 !important;
    width: 22%;
}
.content-table .total-row td {
    background: #1b3a6b;
    color: white;
    font-weight: bold;
    border-top: 3px double #0d1b2a;
}
.content-table .gold-row td {
    background: #fdf8ec;
    font-weight: bold;
    color: #7a5c0a;
}
.content-table .highlight-row td {
    background: #fff3e0;
    color: #5d3a00;
    font-style: italic;
    font-size: 13px;
}

/* ── ACCOUNTING TABLE (T-ACCOUNT / LEDGER STYLE) ────────────── */
.ledger-table {
    width: 100%;
    border-collapse: collapse;
    margin: 14px 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
}
.ledger-table th {
    background: #1b3a6b;
    color: white;
    padding: 8px 12px;
    text-align: center;
    border: 2px solid #0d1b2a;
}
.ledger-table td {
    padding: 7px 12px;
    border: 1px solid #1b3a6b;
    background: white;
}
.ledger-table .dr-side { background: #eaf0f8; }
.ledger-table .cr-side { background: #fdf8ec; }
.ledger-table .total-row td {
    background: #1b3a6b;
    color: white;
    font-weight: bold;
    border-top: 3px double #0d1b2a;
}
.ledger-table .balance-row td {
    background: #f5e6c0;
    font-weight: bold;
    color: #0d1b2a;
}
.ledger-double { border-bottom: 3px double #1b3a6b !important; }

/* ── KEY CONCEPT BOX ────────────────────────────────────────── */
.key-concept {
    background: #e8f0f8;
    padding: 13px 17px;
    border-left: 5px solid #1b3a6b;
    margin: 14px 0;
    border-radius: 0 6px 6px 0;
    font-size: 15px;
}
.key-concept strong { color: #0d1b2a; }

/* ── FORMULA / RULE BOX ─────────────────────────────────────── */
.formula-box {
    background: #e8f0f8;
    border: 2px solid #2d6a9f;
    border-radius: 8px;
    padding: 16px 22px;
    margin: 14px 0;
}
.formula-box h4 {
    color: #0d1b2a;
    margin-bottom: 10px;
    font-size: 15px;
    border-bottom: 1px solid #c5d8ec;
    padding-bottom: 6px;
}
.formula-box .formula {
    font-size: 15px;
    font-weight: bold;
    color: #06111f;
    font-family: 'Times New Roman', Georgia, serif;
    margin: 8px 0;
    background: #c5d8ec;
    padding: 8px 14px;
    border-radius: 4px;
    display: block;
    border-left: 3px solid #1b3a6b;
}

/* ── GOLD RULE BOX ──────────────────────────────────────────── */
.rule-box {
    background: #fdf8ec;
    padding: 13px 17px;
    border-left: 5px solid #c9a84c;
    margin: 14px 0;
    border-radius: 0 6px 6px 0;
    font-size: 14px;
}
.rule-box strong { color: #7a5c0a; }

/* ── WORKED EXAMPLE BOX ─────────────────────────────────────── */
.worked-example {
    background: #f0f4f8;
    border: 1px solid #9bb8d4;
    border-radius: 8px;
    padding: 16px 20px;
    margin: 16px 0;
}
.worked-example h4 {
    color: #0d1b2a;
    font-size: 15px;
    margin-bottom: 10px;
    border-bottom: 1px solid #c5d8ec;
    padding-bottom: 6px;
}
.worked-example .step {
    display: flex;
    gap: 12px;
    margin-bottom: 10px;
    font-size: 14px;
    align-items: flex-start;
}
.step-num {
    background: #1b3a6b;
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
    flex-shrink: 0;
    margin-top: 2px;
}
.step-content { flex: 1; line-height: 1.7; }
.step-content .acc {
    font-family: 'Courier New', monospace;
    background: #e8f0f8;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 13px;
    display: inline-block;
    margin: 2px 0;
    color: #06111f;
}

/* ── TIP BOX ────────────────────────────────────────────────── */
.tip-box {
    background: #fdf8ec;
    padding: 13px 17px;
    border-left: 5px solid #c9a84c;
    margin: 14px 0;
    border-radius: 0 6px 6px 0;
    font-size: 14px;
}
.tip-box strong { color: #7a5c0a; }

/* ── WARN BOX ───────────────────────────────────────────────── */
.warn-box {
    background: #fce8e8;
    padding: 13px 17px;
    border-left: 5px solid #b71c1c;
    margin: 14px 0;
    border-radius: 0 6px 6px 0;
    font-size: 14px;
}
.warn-box strong { color: #7f0000; }

/* ── MEMORY BOX ─────────────────────────────────────────────── */
.memory-box {
    background: #fff9ee;
    border: 1px solid #c9a84c;
    border-radius: 8px;
    padding: 14px 18px;
    margin: 14px 0;
    font-size: 14px;
}
.memory-box h4 { color: #7a5c0a; margin-bottom: 8px; font-size: 14px; }

/* ── ACCOUNTING EQUATION HIGHLIGHT ─────────────────────────── */
.equation-box {
    background: #1b3a6b;
    color: white;
    border-radius: 8px;
    padding: 18px 24px;
    text-align: center;
    margin: 16px 0;
    font-size: 20px;
    font-weight: bold;
    font-family: 'Times New Roman', serif;
    letter-spacing: 1px;
}
.equation-box span { color: #c9a84c; }

/* ── CARD GOLD ──────────────────────────────────────────────── */
.card-gold {
    background: #fdf8ec;
    border: 1px solid #c9a84c;
    border-radius: 6px;
    padding: 14px 16px;
}
.card-gold h4 { color: #7a5c0a; margin-bottom: 6px; }

/* ── PREREQ BANNER ──────────────────────────────────────────── */
.prereq-banner {
    background: #fdf8ec;
    border: 1px solid #c9a84c;
    border-radius: 8px;
    padding: 14px 18px;
    margin-bottom: 20px;
    font-size: 14px;
    color: #4a3500;
}
.prereq-banner strong { color: #7a5c0a; }

/* ── GRID LAYOUTS ───────────────────────────────────────────── */
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.grid-3 { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 14px; margin-top: 14px; }

/* ── CARDS ──────────────────────────────────────────────────── */
.card {
    background: #e8f0f8;
    border: 1px solid #9bb8d4;
    border-radius: 6px;
    padding: 14px 16px;
}
.card h4 { color: #1b3a6b; margin-bottom: 6px; font-size: 15px; }

/* ── DIAGRAM BOX ────────────────────────────────────────────── */
.diagram-box {
    background: #f0f4f8;
    border: 2px dashed #9bb8d4;
    border-radius: 8px;
    padding: 18px;
    text-align: center;
    margin: 14px 0;
}

/* ── PROGRESS BAR ───────────────────────────────────────────── */
.lesson-progress {
    background: white;
    border-radius: 8px;
    padding: 14px 20px;
    margin-bottom: 20px;
    box-shadow: 0 1px 5px rgba(13,27,42,0.09);
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
    font-size: 13px;
    color: #555;
}
.progress-bar-wrap {
    flex: 1;
    background: #c5d8ec;
    border-radius: 20px;
    height: 8px;
    min-width: 120px;
}
.progress-bar-fill {
    background: linear-gradient(90deg, #1b3a6b, #c9a84c);
    height: 8px;
    border-radius: 20px;
}

/* ── SYLLABUS REF BADGE ─────────────────────────────────────── */
.syllabus-ref {
    display: inline-block;
    background: #1b3a6b;
    color: white;
    font-size: 11px;
    padding: 2px 10px;
    border-radius: 20px;
    margin-left: 8px;
    vertical-align: middle;
    font-weight: bold;
}
.syllabus-ref-gold {
    display: inline-block;
    background: #c9a84c;
    color: #06111f;
    font-size: 11px;
    padding: 2px 10px;
    border-radius: 20px;
    margin-left: 8px;
    vertical-align: middle;
    font-weight: bold;
}

/* ── A LEVEL PAPER BADGE ────────────────────────────────────── */
.paper-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: bold;
    padding: 2px 10px;
    border-radius: 20px;
    margin-left: 6px;
    vertical-align: middle;
}
.paper-1 { background: #e8f0f8; color: #1b3a6b; border: 1px solid #2d6a9f; }
.paper-2 { background: #fdf8ec; color: #7a5c0a; border: 1px solid #c9a84c; }
.paper-3 { background: #fce8e8; color: #7f0000; border: 1px solid #b71c1c; }

/* ── EXAM PRACTICE SECTION ──────────────────────────────────── */
.quiz-section {
    background: #e8f0f8;
    padding: 24px 28px;
    border-radius: 8px;
    margin-bottom: 24px;
    border-top: 3px solid #c9a84c;
}
.quiz-section h3 { color: #0d1b2a; margin-bottom: 14px; }

.q-block {
    background: white;
    border-radius: 6px;
    padding: 16px 20px;
    margin-bottom: 16px;
    border: 1px solid #9bb8d4;
}
.q-block p { margin-bottom: 6px; }

.answer {
    background: #fdf8ec;
    border-radius: 4px;
    padding: 10px 14px;
    margin-top: 10px;
    border-left: 3px solid #c9a84c;
    font-size: 14px;
}
.answer .math-ans {
    font-family: 'Courier New', monospace;
    background: #c5d8ec;
    padding: 2px 8px;
    border-radius: 4px;
    font-weight: bold;
    color: #06111f;
    font-size: 14px;
}

.exam-tip {
    background: #fff9ee;
    border-radius: 4px;
    padding: 10px 14px;
    margin-top: 8px;
    border-left: 3px solid #c9a84c;
    font-size: 13px;
}

/* ── TOGGLE BUTTON ──────────────────────────────────────────── */
.toggle-btn {
    background: #1b3a6b;
    color: white;
    border: none;
    padding: 8px 18px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    margin-top: 10px;
    transition: background 0.15s;
    font-family: Georgia, serif;
}
.toggle-btn:hover { background: #06111f; }
.toggle-btn.shown { background: #c9a84c; color: #06111f; }

/* ── NAVIGATION BUTTONS ─────────────────────────────────────── */
.lesson-nav {
    text-align: center;
    margin-top: 10px;
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
}
.btn {
    display: inline-block;
    background: #1b3a6b;
    color: white;
    padding: 12px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 15px;
    transition: background 0.15s;
}
.btn:hover { background: #06111f; }

.btn-gold {
    display: inline-block;
    background: #c9a84c;
    color: #06111f;
    padding: 12px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 15px;
    font-weight: bold;
    transition: background 0.15s;
}
.btn-gold:hover { background: #a07830; color: white; }

.btn-outline {
    display: inline-block;
    background: white;
    color: #1b3a6b;
    border: 2px solid #1b3a6b;
    padding: 11px 28px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 15px;
    transition: background 0.15s;
}
.btn-outline:hover { background: #e8f0f8; }

/* ── T-ACCOUNT SIDE-BY-SIDE ──────────────────────────────────── */
.t-account-wrap {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    border: 2px solid #1b3a6b;
    border-radius: 6px;
    overflow: hidden;
    margin: 14px 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
}
.t-account-wrap .t-account-divider {
    grid-column: 1 / -1;
    background: #1b3a6b;
    color: white;
    text-align: center;
    padding: 10px;
    font-weight: bold;
    font-size: 15px;
    letter-spacing: 0.5px;
}
.t-account-wrap .t-side-title {
    background: #2d6a9f;
    color: white;
    text-align: center;
    padding: 7px;
    font-weight: bold;
    font-size: 13px;
}
.t-account-wrap table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
    font-size: 13px;
}
.t-account-wrap th {
    background: #2d6a9f;
    color: white;
    padding: 6px 10px;
    border: 1px solid #1b3a6b;
    font-size: 12px;
}
.t-account-wrap td {
    padding: 6px 10px;
    border: 1px solid #c5d8ec;
}
.t-account-wrap .dr-side { background: #eaf0f8; }
.t-account-wrap .cr-side { background: #fdf8ec; }
.t-account-wrap .total-row td {
    background: #1b3a6b;
    color: white;
    font-weight: bold;
    border-top: 3px double #0d1b2a;
}
.t-account-wrap .balance-row td {
    background: #f5e6c0;
    font-weight: bold;
    color: #0d1b2a;
}
.t-account-wrap .highlight-entry td {
    background: #c5d8ec;
    font-weight: bold;
    color: #06111f;
    font-style: italic;
}

/* ── FINANCIAL STATEMENT LAYOUT ─────────────────────────────── */
.fin-stmt {
    background: #f0f4f8;
    border: 1px solid #9bb8d4;
    border-radius: 8px;
    padding: 20px 24px;
    margin: 14px 0;
    font-family: 'Courier New', monospace;
    font-size: 14px;
}
.fin-stmt-title {
    font-weight: bold;
    color: #0d1b2a;
    font-size: 16px;
    border-bottom: 2px solid #1b3a6b;
    padding-bottom: 8px;
    margin-bottom: 6px;
    text-align: center;
    font-family: Georgia, serif;
}
.fin-stmt-subtitle {
    text-align: center;
    color: #2d6a9f;
    font-size: 13px;
    margin-bottom: 14px;
    font-family: Georgia, serif;
}
.fs-row {
    display: flex;
    justify-content: space-between;
    padding: 4px 0;
    border-bottom: 1px dotted #c5d8ec;
}
.fs-row.section-head {
    font-weight: bold;
    color: #0d1b2a;
    margin-top: 10px;
    border-bottom: 1px solid #1b3a6b;
    padding-bottom: 4px;
}
.fs-row.indent  { padding-left: 24px; color: #333; }
.fs-row.indent2 { padding-left: 48px; color: #555; }
.fs-row.subtotal {
    font-weight: bold;
    color: #0d1b2a;
    border-top: 1px solid #c5d8ec;
    border-bottom: none;
}
.fs-row.double-line {
    font-weight: bold;
    color: #0d1b2a;
    border-top: 3px double #1b3a6b;
    border-bottom: 3px double #1b3a6b;
    padding: 5px 0;
    margin-top: 4px;
}
.fs-row.total {
    font-weight: bold;
    color: white;
    background: #1b3a6b;
    padding: 7px 10px;
    border-radius: 4px;
    margin-top: 6px;
}
.fs-row.red { color: #b71c1c; }

/* ── COMPARISON TABLE ───────────────────────────────────────── */
.compare-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin: 14px 0;
}
.compare-table th {
    background: #1b3a6b;
    color: white;
    padding: 10px 14px;
    border: 1px solid #2d6a9f;
}
.compare-table td {
    padding: 9px 14px;
    border: 1px solid #c5d8ec;
    vertical-align: top;
}
.compare-table tr:nth-child(even) td { background: #eaf0f8; }
.compare-table .feature-col {
    font-weight: bold;
    color: #0d1b2a;
    background: #e8f0f8 !important;
}

/* ── HIDDEN ANSWER ───────────────────────────────────────────── */
.answer { display: none; }
.answer.visible { display: block; }

/* ── FOOTER ─────────────────────────────────────────────────── */
/* ── FOOTER ──────────────────────────────────────────────── */
footer {
    background: linear-gradient(135deg, #06111f 0%, #0d1b2a 50%, #1b3a6b 100%);
    color: #a8c8f0;
    text-align: center;
    padding: 28px 30px;
    border-top: 4px solid #c9a84c;
    font-size: 13px;
    line-height: 1.9;
}

footer .footer-top {
    font-size: 15px;
    font-weight: bold;
    color: white;
    margin-bottom: 4px;
}

footer .footer-tagline {
    font-size: 13px;
    color: #a8c8f0;
    margin-bottom: 14px;
}

footer .footer-links {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 6px 18px;
    margin-bottom: 14px;
}

footer .footer-links a {
    color: #c9a84c;
    text-decoration: none;
    font-size: 13px;
    font-weight: bold;
    transition: color 0.15s;
}

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

footer .cherry-line {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(183, 28, 28, 0.18);
    border: 1px solid rgba(183, 28, 28, 0.45);
    padding: 6px 18px;
    border-radius: 20px;
    margin-bottom: 14px;
    font-size: 12px;
    color: #ef9a9a;
}

footer .cherry-line a {
    color: #ef9a9a;
    font-weight: bold;
    text-decoration: underline;
}

footer .cherry-line a:hover {
    color: white;
}

footer .footer-copy {
    font-size: 12px;
    color: #607a9a;
    margin-top: 4px;
}

/* ── RESPONSIVE ─────────────────────────────────────────────── */
@media(max-width: 600px) {
    .grid-2, .grid-3     { grid-template-columns: 1fr; }
    .t-account-wrap      { grid-template-columns: 1fr; }
    header h1            { font-size: 20px; }
    .container           { padding: 0 12px 40px; }
    .ledger-table        { font-size: 12px; }
}