/* courthouse.app - Legal Serif Authoritative */
/* Palette: #f5f0e8, #c4b69c, #1a1a1a, #8b0000, #b8860b, #faf8f3, #d4c5a9 */

:root {
    --parchment: #f5f0e8;
    --column: #c4b69c;
    --text: #1a1a1a;
    --red: #8b0000;
    --gold: #b8860b;
    --cream: #faf8f3;
    --rule: #d4c5a9;
}

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

html {
    scroll-behavior: smooth;
}

body {
    background: var(--parchment);
    color: var(--text);
    font-family: 'Lora', serif;
    font-weight: 400;
    font-size: 18px;
    line-height: 1.75;
    min-height: 100vh;
}

/* ==========================================
   SIDEBAR DOCKET
   ========================================== */

.sidebar-docket {
    position: fixed;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    z-index: 100;
    padding: 16px 12px;
    opacity: 0;
    transition: opacity 0.5s ease;
}

.sidebar-docket.visible {
    opacity: 1;
}

.docket-label {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.55rem;
    letter-spacing: 0.2em;
    color: var(--column);
    text-align: center;
    margin-bottom: 12px;
}

.docket-list {
    list-style: none;
}

.docket-item {
    margin-bottom: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.docket-item-num {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.65rem;
    letter-spacing: 0.1em;
    color: var(--column);
    display: block;
    text-align: center;
    padding: 4px 6px;
    border-left: 2px solid transparent;
    transition: all 0.3s ease;
}

.docket-item:hover .docket-item-num,
.docket-item.active .docket-item-num {
    color: var(--red);
    border-left-color: var(--red);
}

/* ==========================================
   OUTER BORDER (Double-line)
   ========================================== */

.court-outer-border {
    max-width: 740px;
    margin: 0 auto;
    padding: 4px;
    border: 1px solid var(--rule);
}

/* ==========================================
   MAIN COURT FRAME (Architectural Columns)
   ========================================== */

.court-frame {
    max-width: 100%;
    margin: 0 auto;
    padding: 0 48px;
    border-left: 1px solid var(--column);
    border-right: 1px solid var(--column);
    min-height: 100vh;
    background: var(--cream);
    position: relative;
}

/* Column decorative caps */
.court-frame::before,
.court-frame::after {
    content: '';
    position: absolute;
    top: 0;
    width: 20px;
    height: 6px;
    background: var(--column);
    opacity: 0.4;
}

.court-frame::before {
    left: -10px;
}

.court-frame::after {
    right: -10px;
}

/* ==========================================
   OPENING ZONE
   ========================================== */

.opening-zone {
    padding-top: 20px;
    padding-bottom: 1rem;
    min-height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

/* ==========================================
   COURT SEAL
   ========================================== */

.seal {
    width: 120px;
    height: 120px;
    margin: 0 auto 32px;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
}

.seal-ring-outer {
    width: 100%;
    height: 100%;
    border: 2px solid var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.seal-ring-outer::before {
    content: '';
    position: absolute;
    inset: 4px;
    border: 1px solid var(--gold);
    border-radius: 50%;
    opacity: 0.5;
}

.seal-ring-inner {
    width: 70%;
    height: 70%;
    border: 1px solid var(--gold);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.seal-core {
    display: flex;
    align-items: center;
    justify-content: center;
}

.seal-scales {
    display: block;
}

.seal-text-ring {
    position: absolute;
    inset: 0;
    pointer-events: none;
}

.seal-text-top,
.seal-text-bottom {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.5rem;
    letter-spacing: 0.2em;
    color: var(--gold);
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    white-space: nowrap;
}

.seal-text-top {
    top: 8px;
}

.seal-text-bottom {
    bottom: 8px;
    font-size: 0.4rem;
}

/* Small seal in adjournment */
.seal-small {
    width: 64px;
    height: 64px;
    margin: 0 auto 20px;
}

.seal-small .seal-ring-outer::before {
    inset: 3px;
}

.seal-small .seal-text-ring {
    display: none;
}

/* ==========================================
   HEADER
   ========================================== */

.court-header {
    text-align: center;
    padding-bottom: 1rem;
}

.session-badge {
    font-family: 'Inter', sans-serif;
    font-size: 0.6rem;
    font-weight: 500;
    letter-spacing: 0.25em;
    color: var(--red);
    border: 1px solid var(--red);
    display: inline-block;
    padding: 0.2rem 1rem;
    border-radius: 9999px;
    margin-bottom: 1.25rem;
    position: relative;
}

.session-badge::before {
    content: '';
    width: 6px;
    height: 6px;
    background: var(--red);
    border-radius: 50%;
    display: inline-block;
    margin-right: 6px;
    vertical-align: middle;
    animation: pulse-dot 2s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.3; }
}

.court-title {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: clamp(2.2rem, 6vw, 3.2rem);
    color: var(--text);
    line-height: 1.2;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.gavel-icon {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.gavel-icon svg {
    display: block;
}

.court-sub {
    font-family: 'Inter', sans-serif;
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--column);
    margin-top: 0.4rem;
    letter-spacing: 0.05em;
}

.court-date {
    font-family: 'Inter', sans-serif;
    font-size: 0.7rem;
    font-weight: 400;
    color: var(--rule);
    margin-top: 0.75rem;
    letter-spacing: 0.08em;
}

/* ==========================================
   ORNAMENTAL RULE
   ========================================== */

.ornamental-rule {
    border: none;
    border-top: 1px solid var(--rule);
    width: 60%;
    margin: 2.5rem auto;
    position: relative;
}

.ornamental-rule::after {
    content: '\25C6';
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--cream);
    padding: 0 10px;
    color: var(--rule);
    font-size: 0.55rem;
}

/* ==========================================
   DOCKET SECTIONS
   ========================================== */

.docket-section {
    padding: 0.5rem 0 1rem;
}

.docket-number {
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    color: var(--red);
    display: block;
    margin-bottom: 0.6rem;
}

.section-heading {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.4rem;
    color: var(--text);
    margin-bottom: 1rem;
    line-height: 1.3;
}

.section-body {
    margin-bottom: 1rem;
    font-size: 1rem;
    line-height: 1.75;
}

.section-body:last-child {
    margin-bottom: 0;
}

.section-list {
    margin: 0.75rem 0 1rem 1.5rem;
    font-size: 1rem;
    line-height: 1.75;
}

.section-list li {
    margin-bottom: 0.35rem;
    padding-left: 0.25rem;
}

.section-list li::marker {
    color: var(--gold);
}

/* ==========================================
   PULL QUOTE
   ========================================== */

.pull-quote {
    padding: 2rem 2.5rem;
    border-left: 3px solid var(--gold);
    margin: 0.5rem 0;
    background: linear-gradient(to right, rgba(184, 134, 11, 0.03), transparent);
}

.quote-text {
    font-family: 'Lora', serif;
    font-style: italic;
    font-size: 1.2rem;
    color: var(--text);
    line-height: 1.7;
    display: block;
    margin-bottom: 0.75rem;
}

.quote-cite {
    font-family: 'Inter', sans-serif;
    font-style: normal;
    font-size: 0.75rem;
    color: var(--column);
    letter-spacing: 0.05em;
}

/* ==========================================
   ADJOURNMENT
   ========================================== */

.adjournment {
    text-align: center;
    padding: 3rem 0 5rem;
}

.adjourn-title {
    font-family: 'Playfair Display', serif;
    font-weight: 700;
    font-size: 1.6rem;
    color: var(--text);
    margin-bottom: 0.75rem;
}

.adjourn-text {
    font-family: 'Lora', serif;
    font-size: 0.95rem;
    color: var(--column);
    max-width: 420px;
    margin: 0 auto 2rem;
    line-height: 1.7;
}

.adjourn-stamp {
    display: inline-block;
    border: 2px solid var(--rule);
    padding: 12px 24px;
    transform: rotate(-2deg);
    opacity: 0.6;
}

.stamp-text {
    font-family: 'Inter', sans-serif;
    font-weight: 600;
    font-size: 0.65rem;
    letter-spacing: 0.2em;
    color: var(--red);
    display: block;
}

.stamp-date {
    font-family: 'Inter', sans-serif;
    font-weight: 400;
    font-size: 0.6rem;
    letter-spacing: 0.1em;
    color: var(--column);
    display: block;
    margin-top: 4px;
}

/* ==========================================
   FADE-IN ANIMATION
   ========================================== */

.fade-in {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Stagger children */
.fade-in:nth-child(2) { transition-delay: 0.1s; }
.fade-in:nth-child(3) { transition-delay: 0.2s; }
.fade-in:nth-child(4) { transition-delay: 0.3s; }

/* ==========================================
   RESPONSIVE
   ========================================== */

@media (max-width: 900px) {
    .sidebar-docket {
        display: none;
    }
}

@media (max-width: 768px) {
    .court-outer-border {
        margin: 0;
        border: none;
        padding: 0;
    }

    .court-frame {
        padding: 0 24px;
        border-left: none;
        border-right: none;
    }

    .court-frame::before,
    .court-frame::after {
        display: none;
    }

    .opening-zone {
        min-height: 80vh;
    }

    .seal {
        width: 96px;
        height: 96px;
    }

    .seal-text-top {
        font-size: 0.4rem;
        top: 6px;
    }

    .seal-text-bottom {
        font-size: 0.35rem;
        bottom: 6px;
    }

    .court-title {
        flex-direction: column;
        gap: 8px;
    }

    .pull-quote {
        padding: 1.5rem 1.5rem;
    }

    .ornamental-rule {
        width: 80%;
    }

    .section-list {
        margin-left: 1rem;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }

    .court-frame {
        padding: 0 16px;
    }

    .seal {
        width: 80px;
        height: 80px;
        margin-bottom: 24px;
    }

    .seal-text-ring {
        display: none;
    }

    .pull-quote {
        padding: 1rem 1rem;
    }

    .adjourn-stamp {
        padding: 8px 16px;
    }
}
