/* Astronomical Events article — magazine layout.
   Scoped to .astro-article so other articles keep their defaults.
   Group accent colors are set via --astro-accent on each section. */

.astro-article {
    max-width: 860px;
    margin: 0 auto;
    line-height: 1.7;
}

/* Hero lede */
.astro-article .astro-lede {
    font-size: 1.2rem;
    line-height: 1.6;
    color: var(--color-text, #1a2332);
    border-left: 3px solid var(--color-warning, #fba540);
    padding: 0.4rem 0 0.4rem 1rem;
    margin: 1.5rem 0 2rem;
    font-style: italic;
}
body.dark-theme .astro-article .astro-lede {
    color: #e8eaed;
}

/* Table of contents */
.astro-toc {
    background: rgba(199, 147, 62, 0.06);
    border: 1px solid rgba(199, 147, 62, 0.25);
    border-radius: 8px;
    padding: 1rem 1.25rem 0.75rem;
    margin: 2rem 0 2.5rem;
}
body.dark-theme .astro-toc {
    background: rgba(199, 147, 62, 0.1);
    border-color: rgba(199, 147, 62, 0.3);
}
.astro-toc__title {
    font-weight: 700;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.8px;
    color: var(--color-warning, #fba540);
    margin: 0 0 0.6rem;
}
.astro-toc__group {
    margin-bottom: 0.5rem;
    padding: 0.3rem 0;
    border-top: 1px dashed rgba(0, 0, 0, 0.08);
}
body.dark-theme .astro-toc__group {
    border-top-color: rgba(255, 255, 255, 0.1);
}
.astro-toc__group:first-of-type {
    border-top: none;
}
.astro-toc__group-label {
    display: inline-block;
    min-width: 8.5rem;
    font-weight: 700;
    font-size: 0.85rem;
    color: var(--astro-accent, #c7933e);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-right: 0.75rem;
    vertical-align: middle;
}
.astro-toc__items {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.3rem 1.1rem;
    margin: 0;
    padding: 0;
    list-style: none;
    vertical-align: middle;
}
.astro-toc__items li {
    display: inline;
}
.astro-toc__items a {
    text-decoration: none;
    color: inherit;
    font-size: 0.95rem;
    border-bottom: 1px dotted transparent;
    transition: color 0.15s, border-color 0.15s;
}
.astro-toc__items a:hover {
    color: var(--astro-accent, #c7933e);
    border-bottom-color: currentColor;
}

/* Section — one per event */
.astro-section {
    margin: 2.5rem 0;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    /* Anchor deep-links (#new-moon, etc.) land with the H2 clearing the 64px fixed topbar */
    scroll-margin-top: 80px;
}
body.dark-theme .astro-section {
    border-top-color: rgba(255, 255, 255, 0.08);
}
.astro-section:first-of-type {
    padding-top: 1rem;
    border-top: none;
}
.astro-section h2 {
    font-size: 1.55rem;
    border-left: 4px solid var(--astro-accent, #c7933e);
    padding-left: 0.8rem;
    margin: 0 0 0.85rem;
    line-height: 1.25;
    scroll-margin-top: 80px;
}
.astro-section__icon {
    display: inline-block;
    margin-right: 0.45rem;
    font-size: 1.3rem;
    vertical-align: -2px;
}

/* At-a-glance panel */
.astro-glance {
    background: rgba(0, 0, 0, 0.035);
    border-left: 3px solid var(--astro-accent, #c7933e);
    padding: 0.55rem 1rem;
    font-size: 0.92rem;
    color: var(--color-text-muted, #555);
    margin: 0 0 1.25rem;
    border-radius: 0 4px 4px 0;
}
body.dark-theme .astro-glance {
    background: rgba(255, 255, 255, 0.04);
    color: #b8c2cc;
}
.astro-glance__label {
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-size: 0.72rem;
    color: var(--astro-accent, #c7933e);
    display: inline-block;
    margin-right: 0.55rem;
}

/* Practical takeaway callout */
.astro-takeaway {
    background: rgba(251, 165, 64, 0.08);
    border-left: 4px solid var(--color-warning, #fba540);
    padding: 0.75rem 1.1rem;
    margin: 1rem 0 0.5rem;
    border-radius: 0 6px 6px 0;
    font-size: 1rem;
    line-height: 1.6;
}
body.dark-theme .astro-takeaway {
    background: rgba(251, 165, 64, 0.14);
}
.astro-takeaway__label {
    display: block;
    font-weight: 700;
    color: var(--color-warning, #fba540);
    text-transform: uppercase;
    letter-spacing: 0.6px;
    font-size: 0.72rem;
    margin-bottom: 0.25rem;
}

/* Group accent colors */
.astro-group-retrogrades   { --astro-accent: #cc8833; }
.astro-group-moon-phases   { --astro-accent: #8899aa; }
.astro-group-ingresses     { --astro-accent: #c7933e; }
.astro-group-eclipses      { --astro-accent: #7b3f99; }

/* Mobile tweaks */
@media (max-width: 575px) {
    .astro-article { padding: 0 0.25rem; }
    .astro-article .astro-lede { font-size: 1.05rem; }
    .astro-toc__group-label { display: block; min-width: 0; margin: 0 0 0.2rem; }
    .astro-section h2 { font-size: 1.35rem; }
}
