/* ── Astro Status Plugin ── */

#astro-status-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    font-family: sans-serif;
    color: #555;
    line-height: 1.7;
}

/* ── Headline (shared rrd-headline pattern) ── */
.rrd-headline {
    margin-bottom: 2rem;
    padding-top: 2rem;
}

.rrd-headline-category {
    font-size: 0.75rem;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #666;
    margin-bottom: 1.2rem;
    font-family: sans-serif;
}

.rrd-headline-title {
    font-family: Georgia, serif;
    font-size: 51.2px;
    font-weight: 700;
    color: #666;
    line-height: 1.05;
    margin-bottom: 1.25rem;
}

.rrd-headline-title em {
    font-size: 51.2px;
    font-style: italic;
    font-weight: 700;
    color: #666;
    display: block;
}

.rrd-headline-subtitle p {
    font-family: Georgia, serif;
    font-size: 1.15rem;
    font-style: italic;
    font-weight: 400;
    color: #666;
    line-height: 1.7;
    margin: 0 0 1.5rem;
}

/* ── Empty state ── */
.as-empty {
    background: #fafbff;
    border: 1px solid #e8edf8;
    border-radius: 12px;
    padding: 2rem 2.5rem;
    text-align: center;
    margin-bottom: 1.5rem;
}

.as-empty-h {
    font-family: Georgia, serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #444;
    margin: 0 0 0.65rem;
}

.as-empty-p {
    font-size: 0.95rem;
    color: #666;
    line-height: 1.6;
    margin: 0 0 1.5rem;
    max-width: 520px;
    margin-left: auto;
    margin-right: auto;
}

.as-empty-note {
    font-size: 0.78rem;
    color: #999;
    margin: 1rem 0 0;
}

.as-empty-line {
    font-family: Georgia, serif;
    font-style: italic;
    color: #888;
    margin: 0;
    font-size: 0.92rem;
}

/* ── Buttons ── */
.as-btn,
.as-btn-secondary {
    display: inline-block;
    padding: 0.7rem 1.4rem;
    font-size: 0.9rem;
    font-weight: 500;
    font-family: sans-serif;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s, border-color 0.15s;
    letter-spacing: 0.02em;
}

.as-btn {
    background: #4169A8;
    color: #fff;
    border: 1px solid #4169A8;
}

.as-btn:hover {
    background: #305090;
    border-color: #305090;
}

.as-btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

.as-btn-secondary {
    background: #fff;
    color: #4169A8;
    border: 1px solid #d0dcf0;
}

.as-btn-secondary:hover {
    border-color: #4169A8;
    background: #f5f7fb;
}

/* ── Big Three chip bar ── */
.as-bar {
    background: #fafbff;
    border: 1px solid #e8edf8;
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
    margin-bottom: 1.25rem;
}

.as-bar-h {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: #4169A8;
    margin: 0 0 0.65rem;
    font-family: sans-serif;
}

.as-chips {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    align-items: center;
}

.as-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #fff;
    border: 1px solid #d0dcf0;
    border-radius: 999px;
    font-size: 0.82rem;
}

.as-chip-l {
    font-size: 0.7rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    font-family: sans-serif;
}

.as-chip-v {
    font-weight: 700;
    color: #444;
    font-family: Georgia, serif;
}

.as-chip-g {
    color: #4169A8;
    font-size: 0.95rem;
    font-family: "DejaVu Sans", "Segoe UI Symbol", "Apple Symbols", "Symbola", sans-serif;
    font-variant-emoji: text;
}

.as-chip-edit {
    margin-left: auto;
    background: transparent;
    border: 0;
    color: #4169A8;
    cursor: pointer;
    font-size: 0.82rem;
    padding: 6px 10px;
    font-family: sans-serif;
    text-decoration: none;
}

.as-chip-edit:hover {
    text-decoration: underline;
}

/* "Not set" placeholder chip — greyed out, italic */
.as-chip--note {
    background: #f5f7fb;
    border-style: dashed;
    border-color: #d0dcf0;
    cursor: help;
}

.as-chip--note .as-chip-v {
    color: #888;
    font-style: italic;
    font-weight: 400;
}

/* ── Hero ── */
.as-hero {
    background: #1F3B6B;
    border-radius: 12px;
    padding: 1.5rem 1.75rem;
    margin-bottom: 1.25rem;
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 1.5rem;
    align-items: center;
}

.as-ring-wrap {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.as-ring-l {
    font-size: 0.7rem;
    color: #A8C0E0;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    margin-top: 6px;
    font-family: sans-serif;
}

.as-hero-eyebrow {
    font-size: 0.72rem;
    color: #A8C0E0;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 0 0 4px;
    font-family: sans-serif;
}

.as-hero-h2 {
    font-family: Georgia, serif;
    font-size: 1.5rem;
    font-weight: 500;
    color: #EAF1FA;
    margin: 0 0 14px;
    line-height: 1.3;
}

.as-hero-ts {
    font-size: 0.72rem;
    color: #A8C0E0;
    margin: 0;
    font-family: sans-serif;
}

/* ── Two-col: influences + tone ── */
.as-2 {
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    gap: 0.85rem;
    margin-bottom: 1.25rem;
}

.as-card {
    background: #fff;
    border: 1px solid #e8edf8;
    border-radius: 10px;
    padding: 1.1rem 1.35rem;
}

.as-card-h {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #4169A8;
    margin: 0 0 0.85rem;
    font-family: sans-serif;
}

.as-inf {
    display: grid;
    grid-template-columns: 32px 1fr auto;
    gap: 10px;
    align-items: start;
    padding: 0.75rem 0;
    border-top: 1px solid #f0f4fb;
}

.as-inf:first-of-type {
    border-top: 0;
    padding-top: 0;
}

.as-inf-glyph {
    font-size: 1.05rem;
    color: #4169A8;
    line-height: 1.6;
    text-align: center;
    font-family: "DejaVu Sans", "Segoe UI Symbol", "Apple Symbols", "Symbola", sans-serif;
    font-variant-emoji: text;
}

.as-inf-meta {
    font-size: 0.88rem;
    color: #444;
    font-family: Georgia, serif;
    line-height: 1.45;
    margin: 0;
}

.as-inf-meta b {
    font-weight: 700;
}

.as-inf-sub {
    font-size: 0.8rem;
    color: #888;
    font-family: sans-serif;
    margin: 3px 0 0;
    line-height: 1.5;
}

.as-pill {
    display: inline-block;
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 999px;
    font-weight: 500;
    letter-spacing: 0.02em;
    white-space: nowrap;
}

.as-pill--h {
    background: #f0f4fb;
    color: #4169A8;
    border: 1px solid #d0dcf0;
}

.as-pill--t {
    background: #fdf6e8;
    color: #a07820;
    border: 1px solid #e0c870;
}

.as-pill--n {
    background: #f5f7fb;
    color: #666;
    border: 1px solid #e0e6f0;
}

/* Tone column */
.as-tone {
    font-family: Georgia, serif;
    font-size: 0.95rem;
    font-style: italic;
    color: #444;
    line-height: 1.65;
    margin: 0 0 0.85rem;
}

.as-tone-q {
    font-size: 0.78rem;
    color: #888;
    font-family: sans-serif;
    margin: 0;
    line-height: 1.55;
}

/* Do / Avoid */
.as-da {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
    margin-bottom: 1.25rem;
}

.as-da-card {
    background: #fff;
    border: 1px solid #e8edf8;
    border-radius: 10px;
    padding: 1.1rem 1.25rem;
    border-left-width: 4px;
    border-left-style: solid;
}

.as-da-card--do {
    border-left-color: #4169A8;
    border-radius: 0 10px 10px 0;
}

.as-da-card--avoid {
    border-left-color: #d4a857;
    border-radius: 0 10px 10px 0;
}

.as-da-h {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    margin: 0 0 0.65rem;
    font-family: sans-serif;
}

.as-da-card--do .as-da-h {
    color: #4169A8;
}

.as-da-card--avoid .as-da-h {
    color: #a07820;
}

.as-da-list {
    margin: 0;
    padding-left: 1.1rem;
}

.as-da-list li {
    font-size: 0.88rem;
    color: #555;
    line-height: 1.6;
    margin-bottom: 0.4rem;
    font-family: sans-serif;
}

.as-da-list li:last-child {
    margin-bottom: 0;
}

/* Timing strip */
.as-time {
    background: #fafbff;
    border: 1px solid #e8edf8;
    border-radius: 12px;
    padding: 1.1rem 1.25rem;
    margin-bottom: 1.25rem;
}

.as-time-h {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #4169A8;
    margin: 0 0 0.85rem;
    font-family: sans-serif;
}

.as-time-svg {
    width: 100%;
    display: block;
}

.as-time-legend {
    display: flex;
    gap: 1.25rem;
    margin-top: 0.65rem;
    font-size: 0.72rem;
    color: #888;
    flex-wrap: wrap;
    font-family: sans-serif;
}

.as-time-legend span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.as-time-legend i {
    width: 9px;
    height: 9px;
    border-radius: 2px;
    display: inline-block;
}

/* ── Lore ── */
.as-lore {
    border-top: 1px solid #e8edf8;
    padding-top: 2rem;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem 2rem;
    margin-bottom: 2rem;
}

.as-lore-block strong {
    display: block;
    font-family: Georgia, serif;
    font-size: 0.95rem;
    font-weight: 700;
    color: #444;
    margin-bottom: 0.4rem;
}

.as-lore-block p {
    font-size: 0.88rem;
    color: #666;
    line-height: 1.7;
    margin: 0;
    font-family: sans-serif;
}

/* ── CTA strip (matching moon plugin) ── */
.as-cta-strip {
    border-left: 4px solid #4169A8;
    border-radius: 0 8px 8px 0;
    background: #f5f7fb;
    overflow: hidden;
    margin-bottom: 1.5rem;
}

.as-cta-main {
    padding: 1.1rem 1.5rem;
    border-bottom: 1px solid #e8edf8;
}

.as-cta-main p {
    font-size: 0.9rem;
    color: #555;
    line-height: 1.6;
    margin: 0;
    font-family: sans-serif;
}

.as-cta-main a {
    color: #4169A8;
    text-decoration: none;
    font-weight: 500;
}

.as-cta-main a:hover { text-decoration: underline; }

.as-cta-free {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.as-free-badge {
    background: #4169A8;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.3rem 0.75rem;
    border-radius: 20px;
    white-space: nowrap;
    flex-shrink: 0;
    font-family: sans-serif;
}

.as-free-text {
    font-size: 0.9rem;
    color: #555;
    line-height: 1.5;
    flex: 1;
    margin: 0;
    font-family: sans-serif;
}

.as-free-text a {
    color: #4169A8;
    font-weight: 500;
    text-decoration: none;
}

.as-free-text a:hover { text-decoration: underline; }

.as-disclaimer {
    font-size: 0.8rem;
    color: #999;
    line-height: 1.6;
    margin: 0;
    font-family: sans-serif;
}

.as-error {
    background: #fdf6e8;
    border-left: 4px solid #d4a857;
    border-radius: 0 8px 8px 0;
    padding: 1rem 1.25rem;
    margin-bottom: 1.5rem;
}

.as-error p {
    font-size: 0.9rem;
    color: #6b5320;
    margin: 0;
    font-family: sans-serif;
}

/* ── Modal ── */
.as-modal {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.as-modal.is-open {
    display: flex;
}

.as-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(31, 59, 107, 0.55);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    cursor: pointer;
}

.as-modal-panel {
    position: relative;
    background: #fff;
    border-radius: 14px;
    max-width: 520px;
    width: 100%;
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
    padding: 2rem 2.25rem 2.25rem;
    box-shadow: 0 24px 60px rgba(31, 59, 107, 0.35);
    font-family: sans-serif;
}

.as-modal-close {
    position: absolute;
    top: 0.75rem;
    right: 0.85rem;
    background: transparent;
    border: 0;
    font-size: 1.6rem;
    line-height: 1;
    color: #999;
    cursor: pointer;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
}

.as-modal-close:hover {
    color: #444;
    background: #f5f7fb;
}

.as-modal-eyebrow {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #4169A8;
    margin: 0 0 0.4rem;
}

.as-modal-title {
    font-family: Georgia, serif;
    font-size: 1.5rem;
    font-weight: 700;
    color: #444;
    margin: 0 0 0.5rem;
    line-height: 1.2;
}

.as-modal-intro {
    font-size: 0.85rem;
    color: #666;
    margin: 0 0 1.5rem;
    line-height: 1.6;
}

/* Form */
.as-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.as-field {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.as-field label {
    font-size: 0.78rem;
    font-weight: 500;
    color: #444;
    font-family: sans-serif;
}

.as-field-hint {
    font-size: 0.72rem;
    color: #888;
    font-weight: 400;
    margin-left: 0.4rem;
}

.as-field input[type="date"],
.as-field input[type="time"],
.as-field input[type="text"],
.as-field input[type="number"],
.as-field select {
    padding: 0.55rem 0.7rem;
    font-size: 0.92rem;
    border: 1px solid #d0dcf0;
    border-radius: 6px;
    font-family: sans-serif;
    background: #fff;
    color: #444;
    transition: border-color 0.15s, box-shadow 0.15s;
}

.as-field input:focus,
.as-field select:focus {
    outline: none;
    border-color: #4169A8;
    box-shadow: 0 0 0 3px rgba(65, 105, 168, 0.15);
}

.as-field input:disabled {
    background: #f5f7fb;
    color: #888;
    cursor: not-allowed;
}

/* "I don't know my birth time" checkbox row */
.as-time-unknown {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.55rem;
    font-size: 0.82rem;
    color: #555;
    font-weight: 400;
    cursor: pointer;
}

.as-time-unknown input[type="checkbox"] {
    accent-color: #4169A8;
    width: 16px;
    height: 16px;
    margin: 0;
    cursor: pointer;
}

.as-time-unknown:hover {
    color: #4169A8;
}

.as-field-hint {
    font-size: 0.72rem;
    color: #888;
    margin: 0.35rem 0 0;
    line-height: 1.5;
}

.as-field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.85rem;
}

/* ── Typeahead place search ── */
.as-field--place {
    position: relative;
}

.as-typeahead {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 4px;
    background: #fff;
    border: 1px solid #d0dcf0;
    border-radius: 8px;
    box-shadow: 0 8px 24px rgba(31, 59, 107, 0.12);
    z-index: 10;
    max-height: 240px;
    overflow-y: auto;
}

.as-ta-item {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    background: transparent;
    border: 0;
    border-bottom: 1px solid #f0f4fb;
    padding: 0.65rem 0.85rem;
    text-align: left;
    cursor: pointer;
    font-family: sans-serif;
    transition: background 0.1s;
}

.as-ta-item:last-child {
    border-bottom: 0;
}

.as-ta-item:hover,
.as-ta-item.is-active {
    background: #f5f7fb;
}

.as-ta-name {
    font-size: 0.92rem;
    font-weight: 500;
    color: #444;
    line-height: 1.3;
}

.as-ta-meta {
    font-size: 0.78rem;
    color: #888;
    line-height: 1.3;
    margin-top: 2px;
}

.as-ta-empty {
    padding: 0.85rem;
    font-size: 0.85rem;
    color: #888;
    font-style: italic;
    font-family: sans-serif;
    text-align: center;
}

.as-form-error {
    background: #fdf6e8;
    border-left: 4px solid #d4a857;
    border-radius: 0 6px 6px 0;
    padding: 0.65rem 0.85rem;
    font-size: 0.82rem;
    color: #6b5320;
    margin: 0;
}

.as-form-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    margin-top: 0.5rem;
}

/* ── Mobile ≤ 768px ── */
@media (max-width: 768px) {
    #astro-status-wrapper {
        padding: 0 20px;
    }

    .rrd-headline-title    { font-size: 2.4rem; }
    .rrd-headline-title em { font-size: 32px; }

    .as-hero {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .as-ring-wrap {
        margin: 0 auto;
    }

    .as-2,
    .as-da,
    .as-lore {
        grid-template-columns: 1fr;
    }

    .as-cta-free {
        flex-direction: column;
        align-items: flex-start;
    }

    .as-modal-panel {
        padding: 1.5rem 1.25rem 1.75rem;
    }

    .as-modal-title {
        font-size: 1.3rem;
    }

    .as-field-row {
        grid-template-columns: 1fr;
    }

    .as-chips {
        flex-direction: column;
        align-items: flex-start;
    }

    .as-chip-edit {
        margin-left: 0;
    }

    /* Timing strip — bars scale down naturally via SVG */
}

@media (max-width: 480px) {
    .as-empty {
        padding: 1.5rem 1.25rem;
    }

    .as-empty-h {
        font-size: 1.25rem;
    }

    .as-form-actions {
        flex-direction: column-reverse;
    }

    .as-form-actions button {
        width: 100%;
    }
}
