/* =========================================================
   Tribal Kite School — Live Wind & Weather
   Scoped under .tks-weather to avoid Bootstrap collisions.
   ========================================================= */

.tks-weather {
    --ocean-900: #04111f;
    --ocean-800: #061a30;
    --ocean-700: #082745;
    --ocean-500: #0e6ba8;
    --teal-400:  #19c2c2;
    --teal-300:  #5ee7df;
    --aqua-200:  #b4f1ee;
    --sun-500:   #ff7a45;
    --sun-400:   #ffb066;
    --warn-500:  #f5b301;
    --danger-500:#ff3b6b;
    --good-500:  #29d398;
    --ink-100:   #f6fbff;
    --ink-300:   #c7d6e3;
    --ink-400:   #8aa1b7;
    --glass-bg:  rgba(255, 255, 255, 0.06);
    --glass-bd:  rgba(255, 255, 255, 0.14);
    --glass-bd-strong: rgba(255, 255, 255, 0.22);

    position: relative;
    color: var(--ink-100);
    font-family: 'Inter', 'Segoe UI', system-ui, -apple-system, sans-serif;
    background:
        radial-gradient(1100px 600px at 85% -10%, rgba(94, 231, 223, 0.18), transparent 60%),
        radial-gradient(800px 500px at 10% 100%, rgba(255, 122, 69, 0.18), transparent 60%),
        linear-gradient(180deg, #03101e 0%, #061a30 45%, #0a2546 100%);
    overflow: hidden;
    isolation: isolate;
    padding: clamp(2.5rem, 5vw, 5rem) 0;
    scroll-margin-top: 120px;
}

/* Decorative ocean shimmer line at the top */
.tks-weather::before {
    content: "";
    position: absolute;
    inset: 0 0 auto 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(94, 231, 223, 0.7), transparent);
    z-index: 2;
}

/* Subtle animated grid */
.tks-weather::after {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.025) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.025) 1px, transparent 1px);
    background-size: 60px 60px;
    -webkit-mask-image: radial-gradient(ellipse at 50% 30%, #000 30%, transparent 75%);
            mask-image: radial-gradient(ellipse at 50% 30%, #000 30%, transparent 75%);
    pointer-events: none;
    z-index: 0;
}

.tks-weather .tks-container {
    position: relative;
    z-index: 1;
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 clamp(1rem, 3vw, 2rem);
}

/* ---------- HEADER ---------- */
.tks-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.75rem;
}
.tks-header__title {
    margin: 0;
    font-size: clamp(1.75rem, 3.5vw, 2.75rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.05;
    background: linear-gradient(120deg, #fff 0%, #b4f1ee 60%, #ffb066 110%);
    -webkit-background-clip: text;
            background-clip: text;
    -webkit-text-fill-color: transparent;
}
.tks-header__sub {
    margin: 0.35rem 0 0;
    color: var(--ink-300);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
}
.tks-live-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.4rem 0.85rem;
    border-radius: 999px;
    background: rgba(41, 211, 152, 0.12);
    border: 1px solid rgba(41, 211, 152, 0.35);
    color: #c5f6e0;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}
.tks-live-pill[data-status="demo"]      { background: rgba(245, 179, 1, 0.12); border-color: rgba(245, 179, 1, 0.4); color: #ffe296; }
.tks-live-pill[data-status="error"]     { background: rgba(255, 59, 107, 0.14); border-color: rgba(255, 59, 107, 0.4); color: #ffc9d6; }
.tks-live-dot {
    width: 8px; height: 8px; border-radius: 50%;
    background: currentColor;
    box-shadow: 0 0 0 0 currentColor;
    animation: tks-pulse 1.8s ease-out infinite;
}
@keyframes tks-pulse {
    0%   { box-shadow: 0 0 0 0   rgba(41,211,152,0.55); }
    70%  { box-shadow: 0 0 0 10px rgba(41,211,152,0);   }
    100% { box-shadow: 0 0 0 0   rgba(41,211,152,0);    }
}

/* ---------- GLASS CARD BASE ---------- */
.tks-glass {
    position: relative;
    background: var(--glass-bg);
    border: 1px solid var(--glass-bd);
    backdrop-filter: blur(18px) saturate(140%);
    -webkit-backdrop-filter: blur(18px) saturate(140%);
    border-radius: 24px;
    box-shadow:
        0 30px 60px -30px rgba(0,0,0,0.55),
        inset 0 1px 0 rgba(255,255,255,0.06);
    transition: transform 0.35s ease, border-color 0.35s ease, box-shadow 0.35s ease;
}
.tks-glass:hover {
    border-color: var(--glass-bd-strong);
}

/* ---------- TOP GRID: HERO + COMPASS ---------- */
.tks-hero {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}
@media (min-width: 960px) {
    .tks-hero { grid-template-columns: 1.55fr 1fr; }
}

/* === HERO CARD === */
.tks-hero-card {
    padding: clamp(1.5rem, 3vw, 2.25rem);
    overflow: hidden;
}
.tks-hero-card[data-tone="good"]  { background: linear-gradient(135deg, rgba(41,211,152,0.16), rgba(8,39,69,0.55)); }
.tks-hero-card[data-tone="hot"]   { background: linear-gradient(135deg, rgba(255,176,102,0.16), rgba(8,39,69,0.6)); }
.tks-hero-card[data-tone="fire"]  { background: linear-gradient(135deg, rgba(255,122,69,0.18), rgba(255,59,107,0.18)); }
.tks-hero-card[data-tone="cool"]  { background: linear-gradient(135deg, rgba(94,231,223,0.18), rgba(8,39,69,0.55)); }
.tks-hero-card[data-tone="mute"]  { background: linear-gradient(135deg, rgba(138,161,183,0.18), rgba(6,26,48,0.65)); }

.tks-location {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--aqua-200);
    font-weight: 600;
    letter-spacing: 0.04em;
    font-size: 0.9rem;
    text-transform: uppercase;
}
.tks-location svg { width: 16px; height: 16px; }

.tks-windnow {
    display: flex;
    align-items: flex-end;
    gap: 0.65rem;
    margin: 1.1rem 0 0.4rem;
}
.tks-windnow__value {
    font-size: clamp(4.5rem, 10vw, 7.5rem);
    font-weight: 800;
    line-height: 0.9;
    letter-spacing: -0.06em;
    background: linear-gradient(180deg, #ffffff 0%, #b4f1ee 100%);
    -webkit-background-clip: text;
            background-clip: text;
    -webkit-text-fill-color: transparent;
    font-variant-numeric: tabular-nums;
}
.tks-windnow__unit {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--ink-300);
    padding-bottom: 0.7rem;
    letter-spacing: 0.08em;
}
.tks-windnow__trend {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.45rem 0.75rem;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    border: 1px solid rgba(255,255,255,0.18);
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--ink-100);
    margin-bottom: 0.9rem;
}
.tks-windnow__trend[data-dir="up"]   { color: #c5f6e0; border-color: rgba(41,211,152,0.35); background: rgba(41,211,152,0.10); }
.tks-windnow__trend[data-dir="down"] { color: #ffd2d2; border-color: rgba(255,122,69,0.35); background: rgba(255,122,69,0.10); }

.tks-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem 1.25rem;
    margin-top: 0.25rem;
    color: var(--ink-300);
    font-size: 0.92rem;
}
.tks-meta-row strong { color: #fff; font-weight: 700; }

.tks-perfect {
    margin-top: 1.4rem;
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.6rem 1rem;
    border-radius: 14px;
    font-weight: 700;
    font-size: 0.95rem;
    letter-spacing: 0.01em;
    border: 1px solid var(--glass-bd-strong);
}
.tks-perfect[data-tone="good"] { background: rgba(41,211,152,0.18); color: #c5f6e0; border-color: rgba(41,211,152,0.45); }
.tks-perfect[data-tone="hot"]  { background: rgba(255,176,102,0.18); color: #ffe5cf; border-color: rgba(255,176,102,0.45); }
.tks-perfect[data-tone="fire"] { background: rgba(255,59,107,0.20); color: #ffd1dd; border-color: rgba(255,59,107,0.50); }
.tks-perfect[data-tone="cool"] { background: rgba(94,231,223,0.18); color: #c8fffb; border-color: rgba(94,231,223,0.50); }
.tks-perfect[data-tone="mute"] { background: rgba(138,161,183,0.18); color: var(--ink-300); border-color: rgba(138,161,183,0.4); }

/* Badges row */
.tks-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-top: 1rem;
}
.tks-tag {
    padding: 0.4rem 0.8rem;
    border-radius: 999px;
    border: 1px solid rgba(255,255,255,0.18);
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    color: var(--ink-100);
    background: rgba(255,255,255,0.06);
}
.tks-tag[data-tone="good"] { background: rgba(41,211,152,0.14);  border-color: rgba(41,211,152,0.4);  color: #c5f6e0; }
.tks-tag[data-tone="hot"]  { background: rgba(255,176,102,0.14); border-color: rgba(255,176,102,0.4); color: #ffe5cf; }
.tks-tag[data-tone="fire"] { background: rgba(255,59,107,0.16);  border-color: rgba(255,59,107,0.5);  color: #ffd1dd; }
.tks-tag[data-tone="warn"] { background: rgba(245,179,1,0.14);   border-color: rgba(245,179,1,0.4);   color: #ffe296; }
.tks-tag[data-tone="cool"] { background: rgba(94,231,223,0.14);  border-color: rgba(94,231,223,0.45); color: #c8fffb; }
.tks-tag[data-tone="mute"] { background: rgba(138,161,183,0.15); border-color: rgba(138,161,183,0.4); color: var(--ink-300); }

/* === COMPASS CARD === */
.tks-compass-card {
    padding: clamp(1.25rem, 2.5vw, 1.75rem);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}
.tks-compass-card h3 {
    margin: 0 0 1rem;
    font-size: 1rem;
    color: var(--ink-300);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.tks-compass {
    --size: min(280px, 60vw);
    width: var(--size);
    height: var(--size);
    position: relative;
    border-radius: 50%;
    background:
        radial-gradient(circle at 50% 50%, rgba(94,231,223,0.10), transparent 65%),
        conic-gradient(from 0deg, rgba(94,231,223,0.18), rgba(255,176,102,0.18), rgba(94,231,223,0.18));
    box-shadow:
        inset 0 0 0 1px rgba(255,255,255,0.18),
        inset 0 0 40px rgba(94,231,223,0.10),
        0 25px 50px -25px rgba(0,0,0,0.7);
}
.tks-compass__inner {
    position: absolute;
    inset: 14px;
    border-radius: 50%;
    background:
        radial-gradient(circle at 50% 30%, rgba(94,231,223,0.10), transparent 60%),
        linear-gradient(180deg, #061a30, #04111f);
    border: 1px solid rgba(255,255,255,0.10);
}
.tks-compass__cardinal {
    position: absolute;
    font-size: 0.78rem;
    color: var(--ink-300);
    font-weight: 700;
    letter-spacing: 0.1em;
}
.tks-compass__cardinal--n { top: 10px;    left: 50%; transform: translateX(-50%); color: var(--aqua-200); }
.tks-compass__cardinal--s { bottom: 10px; left: 50%; transform: translateX(-50%); }
.tks-compass__cardinal--e { right: 12px;  top: 50%;  transform: translateY(-50%); }
.tks-compass__cardinal--w { left: 12px;   top: 50%;  transform: translateY(-50%); }
.tks-compass__needle {
    position: absolute;
    top: 50%; left: 50%;
    width: 4px; height: 42%;
    background: linear-gradient(180deg, #ff7a45 0%, #ff3b6b 100%);
    border-radius: 4px;
    transform-origin: 50% 100%;
    transform: translate(-50%, -100%) rotate(0deg);
    transition: transform 1.2s cubic-bezier(0.34, 1.56, 0.64, 1);
    box-shadow: 0 0 18px rgba(255, 122, 69, 0.6);
}
.tks-compass__needle::after {
    content: "";
    position: absolute;
    top: -6px; left: 50%;
    width: 0; height: 0;
    transform: translateX(-50%);
    border-left: 8px solid transparent;
    border-right: 8px solid transparent;
    border-bottom: 12px solid #ff7a45;
    filter: drop-shadow(0 0 6px rgba(255, 122, 69, 0.7));
}
.tks-compass__tail {
    position: absolute;
    top: 50%; left: 50%;
    width: 3px; height: 30%;
    background: rgba(255,255,255,0.25);
    border-radius: 3px;
    transform-origin: 50% 0;
    transform: translate(-50%, 0) rotate(0deg);
    transition: transform 1.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.tks-compass__hub {
    position: absolute;
    top: 50%; left: 50%;
    width: 22px; height: 22px;
    border-radius: 50%;
    transform: translate(-50%, -50%);
    background: radial-gradient(circle, #fff 0%, #5ee7df 60%, #082745 100%);
    box-shadow: 0 0 16px rgba(94,231,223,0.7);
}
.tks-compass__center {
    position: absolute;
    top: 50%; left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    pointer-events: none;
}
.tks-compass__center-val {
    font-size: 1.8rem;
    font-weight: 800;
    line-height: 1;
    color: #fff;
    font-variant-numeric: tabular-nums;
}
.tks-compass__center-lbl {
    margin-top: 0.4rem;
    font-size: 0.7rem;
    letter-spacing: 0.18em;
    color: var(--ink-300);
    text-transform: uppercase;
}

.tks-compass-card__footer {
    margin-top: 1.1rem;
    display: flex;
    justify-content: space-around;
    width: 100%;
    gap: 0.5rem;
}
.tks-compass-card__footer > div {
    flex: 1;
    padding: 0.6rem;
    border-radius: 12px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.08);
}
.tks-compass-card__footer .lbl {
    display: block;
    font-size: 0.65rem;
    letter-spacing: 0.15em;
    color: var(--ink-400);
    text-transform: uppercase;
}
.tks-compass-card__footer .val {
    display: block;
    margin-top: 0.2rem;
    font-size: 1.1rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
}

/* ---------- BANNER ---------- */
.tks-banner {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem 1.25rem;
    border-radius: 18px;
    margin-bottom: 1.25rem;
    background: linear-gradient(90deg, rgba(255,122,69,0.18), rgba(94,231,223,0.10));
    border: 1px solid rgba(255,255,255,0.18);
    font-size: clamp(0.95rem, 1.6vw, 1.1rem);
    font-weight: 600;
    color: #fff;
}
.tks-banner__icon {
    flex: 0 0 auto;
    width: 38px; height: 38px;
    border-radius: 12px;
    display: grid; place-items: center;
    background: rgba(255,255,255,0.10);
    font-size: 1.2rem;
}

/* ---------- CHART + KITE GRID ---------- */
.tks-mid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.25rem;
    margin-bottom: 1.25rem;
}
@media (min-width: 1024px) {
    .tks-mid { grid-template-columns: 1.7fr 1fr; }
}
.tks-chart-card { padding: 1.5rem; }
.tks-chart-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-bottom: 1rem;
}
.tks-chart-card__head h3 {
    margin: 0;
    font-size: 1.1rem;
    letter-spacing: 0.04em;
    font-weight: 700;
    color: #fff;
}
.tks-legend {
    display: inline-flex;
    gap: 0.85rem;
    font-size: 0.78rem;
    color: var(--ink-300);
}
.tks-legend span { display: inline-flex; align-items: center; gap: 0.4rem; }
.tks-legend i {
    display: inline-block;
    width: 18px; height: 3px; border-radius: 2px;
}
.tks-legend i.avg  { background: linear-gradient(90deg, #5ee7df, #19c2c2); }
.tks-legend i.gust { background: linear-gradient(90deg, #ffb066, #ff7a45); }
.tks-legend i.lull { background: linear-gradient(90deg, #3f86bd, #2f6f9f); }

.tks-chart-wrap {
    position: relative;
    height: clamp(220px, 32vw, 320px);
    width: 100%;
}

/* === LIVE WIND SPEED CARD (measured observations) === */
.tks-windobs {
    padding: 1.5rem;
    margin-bottom: 1.25rem;
}
.tks-windobs__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.6rem 1.25rem;
    margin-bottom: 0.5rem;
}
.tks-windobs__title {
    display: flex;
    align-items: baseline;
    gap: 0.6rem;
    flex-wrap: wrap;
}
.tks-windobs__title h3 {
    margin: 0;
    font-size: 1.1rem;
    letter-spacing: 0.04em;
    font-weight: 700;
    color: #fff;
}
.tks-windobs__device {
    font-size: 0.72rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    color: var(--teal-300);
    background: rgba(94, 231, 223, 0.10);
    border: 1px solid rgba(94, 231, 223, 0.22);
    border-radius: 999px;
    padding: 0.15rem 0.6rem;
}
.tks-windobs__reading {
    font-size: 0.92rem;
    color: var(--ink-300);
    display: flex;
    align-items: baseline;
    gap: 0.4rem;
    flex-wrap: wrap;
}
.tks-windobs__reading strong {
    font-size: 1.35rem;
    font-weight: 800;
    color: #fff;
}
.tks-windobs__range { color: var(--ink-400); }
.tks-windobs__card {
    font-weight: 700;
    color: var(--teal-300);
}
.tks-windobs__when {
    font-size: 0.78rem;
    color: var(--ink-400);
}
.tks-windobs__chartwrap {
    position: relative;
    height: clamp(240px, 34vw, 340px);
    width: 100%;
    margin-top: 0.35rem;
}
.tks-windobs__note {
    margin: 0.75rem 0 0;
    font-size: 0.76rem;
    color: var(--ink-400);
}

/* === KITE SIZE CARD === */
.tks-kite-card {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}
.tks-kite-card h3 {
    margin: 0 0 1rem;
    font-size: 1rem;
    color: var(--ink-300);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.tks-kite-recommend {
    display: flex;
    align-items: center;
    gap: 1.1rem;
    padding: 1rem;
    border-radius: 16px;
    background: linear-gradient(135deg, rgba(255,176,102,0.12), rgba(94,231,223,0.10));
    border: 1px solid rgba(255,255,255,0.18);
    margin-bottom: 1rem;
}
.tks-kite-recommend__icon {
    width: 56px; height: 56px;
    border-radius: 16px;
    background: linear-gradient(135deg, #ff7a45, #ffb066);
    display: grid; place-items: center;
    font-size: 1.6rem;
    box-shadow: 0 10px 24px -8px rgba(255,122,69,0.55);
}
/* Wind out of rideable range (<8 or >30 kts): show the size but signal "paused". */
.tks-kite-recommend[data-state="hold"] {
    background: linear-gradient(135deg, rgba(245,179,1,0.14), rgba(255,122,69,0.08));
    border-color: rgba(245,179,1,0.40);
}
.tks-kite-recommend[data-state="hold"] .tks-kite-recommend__size { color: var(--warn-500); }
.tks-kite-recommend__size {
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
}
.tks-kite-recommend__lbl {
    color: var(--ink-300);
    font-size: 0.85rem;
    margin-top: 0.25rem;
}
.tks-kite-scale {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 0.4rem;
}
.tks-kite-scale > div {
    padding: 0.55rem 0.4rem;
    border-radius: 10px;
    text-align: center;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.08);
    font-size: 0.7rem;
    color: var(--ink-300);
    transition: all 0.3s ease;
}
.tks-kite-scale > div b {
    display: block;
    color: #fff;
    font-size: 0.95rem;
    font-weight: 800;
    margin-bottom: 0.15rem;
}
.tks-kite-scale > div.active {
    background: linear-gradient(135deg, rgba(255,122,69,0.30), rgba(255,176,102,0.22));
    border-color: rgba(255,176,102,0.55);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 10px 22px -10px rgba(255,122,69,0.55);
}

.tks-best-window {
    margin-top: 1rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    background: rgba(94,231,223,0.10);
    border: 1px solid rgba(94,231,223,0.30);
    display: flex; align-items: center; gap: 0.7rem;
    font-size: 0.92rem;
}
.tks-best-window__time { font-weight: 800; color: var(--aqua-200); }

/* ---------- WEIGHT CONTROL (kite calculator) ---------- */
.tks-weight {
    margin: 0 0 1rem;
    padding: 0.9rem 1rem 1rem;
    border-radius: 14px;
    background: rgba(94,231,223,0.06);
    border: 1px solid rgba(94,231,223,0.22);
}
.tks-weight__top {
    display: flex; align-items: center; justify-content: space-between;
    margin-bottom: 0.6rem;
}
.tks-weight__top label {
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.06em;
    text-transform: uppercase; color: var(--ink-300);
}
.tks-weight__unit {
    display: inline-flex; border-radius: 9px; overflow: hidden;
    border: 1px solid rgba(94,231,223,0.30);
}
.tks-weight__unit button {
    appearance: none; border: 0; cursor: pointer;
    padding: 0.2rem 0.7rem; font-size: 0.78rem; font-weight: 700;
    background: transparent; color: var(--ink-400); transition: all 0.2s ease;
}
.tks-weight__unit button.is-active {
    background: linear-gradient(135deg, var(--teal-400), var(--teal-300));
    color: #04111f;
}
/* Range slider — teal track + glowing thumb */
.tks-weight input[type="range"] {
    -webkit-appearance: none; appearance: none;
    width: 100%; height: 6px; border-radius: 6px; outline: none; cursor: pointer;
    background: linear-gradient(90deg, var(--teal-300) 0%, var(--teal-400) 100%);
    background-color: rgba(255,255,255,0.10);
}
.tks-weight input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none; appearance: none;
    width: 20px; height: 20px; border-radius: 50%;
    background: #fff; border: 3px solid var(--teal-400);
    box-shadow: 0 0 0 4px rgba(25,194,194,0.25), 0 6px 14px -4px rgba(0,0,0,0.6);
    transition: transform 0.15s ease;
}
.tks-weight input[type="range"]::-webkit-slider-thumb:active { transform: scale(1.15); }
.tks-weight input[type="range"]::-moz-range-thumb {
    width: 20px; height: 20px; border-radius: 50%; border: 3px solid var(--teal-400);
    background: #fff; box-shadow: 0 0 0 4px rgba(25,194,194,0.25);
}
.tks-weight__readout {
    display: flex; align-items: center; gap: 0.5rem; margin-top: 0.7rem;
    flex-wrap: wrap;
}
.tks-weight__readout input[type="number"] {
    width: 68px; padding: 0.35rem 0.5rem; text-align: center;
    font-size: 1rem; font-weight: 800; color: #fff;
    background: rgba(255,255,255,0.07); border: 1px solid var(--glass-bd);
    border-radius: 9px; outline: none;
    -moz-appearance: textfield;
}
.tks-weight__readout input[type="number"]:focus { border-color: var(--teal-400); }
.tks-weight__unit-lbl { font-weight: 700; color: var(--ink-300); font-size: 0.9rem; }
.tks-weight__note {
    margin-top: 0.55rem; font-size: 0.8rem; color: var(--warn-500); font-weight: 600;
}
.tks-weight__note:empty { display: none; }
.tks-weight__help {
    margin-top: 0.5rem; font-size: 0.74rem; color: var(--ink-400); line-height: 1.3;
}

/* ---------- METRICS GRID ---------- */
.tks-metrics {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.85rem;
    margin-bottom: 1.25rem;
}
@media (min-width: 600px)  { .tks-metrics { grid-template-columns: repeat(4, 1fr); } }
@media (min-width: 1024px) { .tks-metrics { grid-template-columns: repeat(4, 1fr); } }

.tks-metric {
    padding: 1.1rem;
    border-radius: 18px;
    background: var(--glass-bg);
    border: 1px solid var(--glass-bd);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: transform 0.3s ease, border-color 0.3s ease, background 0.3s ease;
    cursor: default;
}
.tks-metric:hover {
    transform: translateY(-4px);
    border-color: rgba(94,231,223,0.40);
    background: rgba(94,231,223,0.08);
}
.tks-metric__icon {
    width: 38px; height: 38px;
    display: grid; place-items: center;
    border-radius: 12px;
    background: rgba(255,255,255,0.08);
    color: var(--aqua-200);
    margin-bottom: 0.7rem;
}
.tks-metric__icon svg { width: 20px; height: 20px; }
.tks-metric__lbl {
    font-size: 0.7rem;
    letter-spacing: 0.15em;
    color: var(--ink-400);
    text-transform: uppercase;
    font-weight: 600;
}
.tks-metric__val {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.1;
    color: #fff;
    font-variant-numeric: tabular-nums;
    margin-top: 0.25rem;
}
.tks-metric__unit {
    font-size: 0.85rem;
    color: var(--ink-300);
    font-weight: 600;
    margin-left: 0.2rem;
}
.tks-metric__sub {
    margin-top: 0.4rem;
    font-size: 0.75rem;
    color: var(--ink-400);
}

/* ---------- HOURLY FORECAST STRIP ---------- */
.tks-forecast {
    padding: 1.5rem;
}
.tks-forecast h3 {
    margin: 0 0 1rem;
    font-size: 1rem;
    color: var(--ink-300);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}
.tks-forecast__strip {
    display: flex;
    gap: 0.75rem;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    padding-bottom: 0.5rem;
    -webkit-overflow-scrolling: touch;
}
.tks-forecast__strip::-webkit-scrollbar { height: 6px; }
.tks-forecast__strip::-webkit-scrollbar-track { background: transparent; }
.tks-forecast__strip::-webkit-scrollbar-thumb { background: rgba(94,231,223,0.30); border-radius: 99px; }

.tks-fc-card {
    flex: 0 0 110px;
    scroll-snap-align: start;
    padding: 0.9rem 0.7rem;
    text-align: center;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 16px;
    transition: transform 0.3s ease, border-color 0.3s ease;
}
.tks-fc-card:hover {
    transform: translateY(-3px);
    border-color: rgba(94,231,223,0.40);
}
.tks-fc-card.is-best {
    background: linear-gradient(135deg, rgba(255,122,69,0.22), rgba(255,176,102,0.10));
    border-color: rgba(255,176,102,0.5);
}
.tks-fc-card__time {
    font-size: 0.78rem;
    color: var(--ink-300);
    letter-spacing: 0.1em;
    font-weight: 600;
}
.tks-fc-card__icon {
    margin: 0.4rem 0;
    font-size: 1.6rem;
    line-height: 1;
}
.tks-fc-card__wind {
    font-size: 1.25rem;
    font-weight: 800;
    color: #fff;
    font-variant-numeric: tabular-nums;
}
.tks-fc-card__unit {
    font-size: 0.7rem;
    color: var(--ink-400);
    text-transform: uppercase;
    letter-spacing: 0.1em;
}
.tks-fc-card__dir {
    margin-top: 0.4rem;
    font-size: 0.7rem;
    color: var(--ink-300);
}
.tks-fc-card__dir svg {
    width: 14px; height: 14px;
    vertical-align: -2px;
    transition: transform 0.6s ease;
}

/* ---------- SKELETON ---------- */
.tks-skel {
    background: linear-gradient(90deg, rgba(255,255,255,0.05) 0%, rgba(255,255,255,0.12) 50%, rgba(255,255,255,0.05) 100%);
    background-size: 200% 100%;
    animation: tks-shimmer 1.4s linear infinite;
    border-radius: 8px;
    color: transparent;
}
@keyframes tks-shimmer {
    from { background-position: 200% 0; }
    to   { background-position: -200% 0; }
}

/* ---------- ERROR STATE ---------- */
.tks-error {
    display: none;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    background: rgba(255,59,107,0.10);
    border: 1px solid rgba(255,59,107,0.35);
    color: #ffd1dd;
    font-size: 0.85rem;
}
.tks-error.is-visible { display: flex; }

/* ---------- FOOTER NOTE ---------- */
.tks-footnote {
    margin-top: 0.5rem;
    color: var(--ink-400);
    font-size: 0.78rem;
    text-align: center;
}
.tks-footnote a { color: var(--aqua-200); text-decoration: none; }
.tks-footnote a:hover { text-decoration: underline; }

/* ---------- WIND STREAMS (decorative) ---------- */
.tks-stream {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}
.tks-stream::before,
.tks-stream::after {
    content: "";
    position: absolute;
    width: 240px; height: 1px;
    background: linear-gradient(90deg, transparent, rgba(94,231,223,0.6), transparent);
    animation: tks-stream-fly 6s linear infinite;
}
.tks-stream::before { top: 30%; left: -240px; }
.tks-stream::after  { top: 65%; left: -240px; animation-delay: 2.5s; opacity: 0.6; }
@keyframes tks-stream-fly {
    from { transform: translateX(0); }
    to   { transform: translateX(calc(100vw + 240px)); }
}

@media (prefers-reduced-motion: reduce) {
    .tks-stream::before, .tks-stream::after,
    .tks-live-dot,
    .tks-compass__needle, .tks-compass__tail { animation: none !important; transition: none !important; }
}
