/*
---------------------------------------------------------
BookTeeOff Weather ([bto_weather])
Rendered as a plain section (no card box) to match the other detail-page
sections; the title reuses the theme's .bto-gc-h2.
---------------------------------------------------------
*/

.bto-weather {
    color: var(--bto-ink, #1c1d1f);
}

.bto-weather-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 1rem;
}

/* The title is a .bto-gc-h2 — drop its bottom margin here so it sits on the
   toggle row. */
.bto-weather-top .bto-gc-h2 {
    margin: 0;
}

.bto-weather-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.bto-weather-date {
    font: inherit;
    font-size: 0.85rem;
    padding: 5px 10px;
    border: 1px solid var(--bto-border-strong, #c6d3cc);
    border-radius: var(--bto-radius-sm, 8px);
    background: var(--bto-surface, #fff);
    color: var(--bto-ink, #1c1d1f);
    cursor: pointer;
}

.bto-weather-toggle {
    display: inline-flex;
    border: 1px solid var(--bto-border-strong, #c6d3cc);
    border-radius: var(--bto-radius-sm, 8px);
    overflow: hidden;
    flex: 0 0 auto;
}

.bto-weather-toggle .bto-wt {
    border: 0;
    background: var(--bto-surface, #fff);
    color: var(--bto-ink-2, #4c5254);
    padding: 9px 12px;
    font-size: 0.85rem;
    cursor: pointer;
    line-height: 1.6;
}

.bto-weather-toggle .bto-wt.is-active {
    /* Same voice as the selected day card: light green bg, dark green text. */
    background: var(--bto-weather-bg, #e8f9f0);
    color: var(--bto-green, #027a4e);
    font-weight: 600;
}

.bto-weather-today {
    margin: 0 0 14px;
    line-height: 1.7;
    color: var(--bto-ink-2, #4c5254);
}

.bto-weather-today strong,
.bto-weather-daylabel {
    color: var(--bto-ink, #1c1d1f);
    font-weight: 600;
}

.bto-weather-note {
    margin: -4px 0 14px;
    font-size: 0.8rem;
    color: var(--bto-ink-2, #4c5254);
    background: var(--bto-surface-2, #f2f6f4);
    border-left: 3px solid var(--bto-weather-accent, #66cc9f);
    border-radius: 4px;
    padding: 8px 10px;
    line-height: 1.5;
}

.bto-weather-note[hidden] {
    display: none;
}

.bto-weather-forecast {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
}

.bto-wf-day {
    border: 1px solid var(--bto-border, #e0e8e4);
    border-radius: var(--bto-radius-sm, 8px);
    padding: 12px 6px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    transition: border-color .15s, background .15s;
}

.bto-wf-day:hover {
    border-color: var(--bto-border-strong, #c6d3cc);
}

.bto-wf-day.is-selected {
    border: 2px solid var(--bto-weather-accent, #66cc9f);
    background: var(--bto-weather-bg, #e8f9f0);
    /* 1px slimmer padding compensates the thicker border — no layout shift */
    padding: 11px 5px;
}

.bto-wf-name {
    font-weight: 600;
    font-size: 0.82rem;
}

.bto-wf-icon {
    width: 30px;
    height: 30px;
    color: var(--bto-weather-accent, #66cc9f);
}

.bto-wf-temp {
    font-size: 0.8rem;
    color: var(--bto-ink-2, #4c5254);
    white-space: nowrap;
}

@media (max-width: 900px) {
    .bto-weather-forecast {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (max-width: 480px) {
    .bto-weather-forecast {
        grid-template-columns: repeat(3, 1fr);
    }
}
