/* =========================================================
   SATAID Web
   Satellite + Radar Compare v0.1
   ========================================================= */

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    background: #edf3f4;
    color: #202b2f;
}

.compare-workspace {
    width: min(1800px, calc(100% - 24px));
    margin: 0 auto;
    padding: 14px 0 22px;
}


/* ---------------------------------------------------------
   PAGE TITLE
--------------------------------------------------------- */

.compare-title {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 20px;

    margin-bottom: 10px;
    padding: 0 4px;
}

.compare-kicker {
    display: block;

    margin-bottom: 2px;

    color: #657b83;

    font-size: 11px;
    font-weight: 800;
    letter-spacing: 1.2px;
}

.compare-title h1 {
    margin: 0;

    color: #183a43;

    font-size: 23px;
    line-height: 1.15;
}

.compare-note {
    color: #718087;

    font-size: 12px;
}


/* ---------------------------------------------------------
   TWO IMAGE WORKSPACES
--------------------------------------------------------- */

.compare-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 10px;
}

.compare-panel {
    min-width: 0;

    overflow: hidden;

    background: #ffffff;

    border: 1px solid #d4dfe2;
    border-radius: 9px;

    box-shadow:
        0 3px 12px rgba(29, 55, 64, 0.06);
}


/* ---------------------------------------------------------
   PANEL HEADER
--------------------------------------------------------- */

.panel-heading {
    min-height: 55px;

    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;

    padding: 9px 12px;

    background: #e5f3eb;

    border-bottom: 1px solid #d0e1d5;
}

.radar-panel .panel-heading {
    background: #e6f3f6;
    border-bottom-color: #cee2e6;
}

.panel-heading strong {
    display: block;

    color: #20362e;

    font-size: 15px;
}

.panel-heading span:not(.status-badge) {
    display: block;

    margin-top: 2px;

    color: #667b72;

    font-size: 11px;
}

.status-badge {
    flex: 0 0 auto;

    padding: 4px 8px;

    color: #28563a;

    background: #f7fbf8;

    border: 1px solid #c9ddce;
    border-radius: 999px;

    font-size: 11px;
    font-weight: 800;
}


/* ---------------------------------------------------------
   SATELLITE PRODUCTS
--------------------------------------------------------- */

.product-tabs {
    display: flex;
    gap: 5px;

    padding: 7px 8px;

    overflow-x: auto;

    background: #f8faf9;

    border-bottom: 1px solid #e1e7e8;
}

.product-tabs button,
.viewer-controls button,
.radar-toolbar button {
    min-height: 31px;

    padding: 5px 10px;

    color: #29373b;

    background: #ffffff;

    border: 1px solid #cbd7da;
    border-radius: 5px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 700;

    cursor: pointer;
}

.product-tabs button:hover,
.viewer-controls button:hover,
.radar-toolbar button:hover {
    background: #edf7f0;
}

.product-tabs button.active {
    color: #183d26;

    background: #dcefe1;

    border-color: #afd1b7;

    box-shadow:
        inset 3px 0 0 #5ca66d;
}


/* ---------------------------------------------------------
   IMAGE AREA
--------------------------------------------------------- */

.image-stage {
    position: relative;

    height: min(65vh, 700px);
    min-height: 430px;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;

    background: #050708;
}

.image-stage img {
    display: block;

    width: 100%;
    height: 100%;

    object-fit: contain;

    user-select: none;
}

.image-message {
    position: absolute;
    inset: 0;

    display: flex;
    align-items: center;
    justify-content: center;

    padding: 20px;

    color: #dfe7e9;

    background: #111719;

    text-align: center;

    font-size: 13px;
}

.image-message.hidden {
    display: none;
}


/* ---------------------------------------------------------
   SATELLITE CONTROLS
--------------------------------------------------------- */

.viewer-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;

    padding: 7px 8px 4px;
}

.timeline-row {
    padding: 2px 12px;
}

.timeline-row input {
    width: 100%;
}

.time-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;

    padding: 3px 12px 9px;

    color: #607077;

    font-size: 11px;
}


/* ---------------------------------------------------------
   RADAR TOOLBAR
--------------------------------------------------------- */

.radar-toolbar {
    min-height: 46px;

    display: flex;
    align-items: center;
    gap: 7px;

    padding: 7px 9px;

    background: #f8fafb;

    border-bottom: 1px solid #e1e7e9;
}

.radar-toolbar label {
    color: #52646a;

    font-size: 12px;
    font-weight: 700;
}

.radar-toolbar select {
    min-width: 230px;
    max-width: 100%;

    height: 31px;

    padding: 4px 8px;

    color: #27383d;

    background: #ffffff;

    border: 1px solid #cbd7da;
    border-radius: 5px;

    font-family: inherit;
    font-size: 12px;
}

.radar-info {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;

    min-height: 40px;

    padding: 7px 11px;

    color: #66777d;

    background: #fafbfb;

    border-top: 1px solid #e3e8e9;

    font-size: 11px;
}


/* ---------------------------------------------------------
   HEADER TYPOGRAPHY
--------------------------------------------------------- */

@media (min-width: 1350px) {
    .main-nav a {
        font-size: 21px;
        font-weight: 700;
    }
}


/* ---------------------------------------------------------
   RESPONSIVE
--------------------------------------------------------- */

@media (max-width: 1050px) {

    .compare-grid {
        grid-template-columns: 1fr;
    }

    .image-stage {
        height: 620px;
    }
}

@media (max-width: 700px) {

    .compare-workspace {
        width: calc(100% - 12px);
    }

    .compare-title {
        align-items: flex-start;
        flex-direction: column;
        gap: 3px;
    }

    .compare-note {
        display: none;
    }

    .image-stage {
        height: 65vh;
        min-height: 340px;
    }

    .radar-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .radar-toolbar select {
        width: 100%;
    }

    .time-row,
    .radar-info {
        align-items: flex-start;
        flex-direction: column;
    }
}


/* =========================================================
   Radar Viewer v0.2
   Latest / LOOP
   ========================================================= */

.radar-mode-tabs {
    display: flex;
    align-items: center;
    gap: 6px;

    padding: 7px 9px;

    background: #edf6f7;

    border-bottom: 1px solid #d9e7e9;
}

.radar-mode-tabs button {
    min-height: 31px;

    padding: 5px 16px;

    color: #304247;

    background: #ffffff;

    border: 1px solid #c8d7da;
    border-radius: 5px;

    font-family: inherit;
    font-size: 12px;
    font-weight: 800;

    cursor: pointer;
}

.radar-mode-tabs button:hover {
    background: #edf7f3;
}

.radar-mode-tabs button.active {
    color: #173d2b;

    background: #dcefe3;

    border-color: #a9cfb5;

    box-shadow:
        inset 3px 0 0 #54a36a;
}

.radar-mode-tabs #radarLoopMode.active {
    color: #244a56;

    background: #dceef2;

    border-color: #aacdd5;

    box-shadow:
        inset 3px 0 0 #5196a7;
}

.radar-toolbar {
    flex-wrap: wrap;
}

.radar-toolbar select {
    flex: 1 1 320px;
}

.radar-toolbar optgroup {
    color: #29434a;
    font-weight: 800;
}

.radar-toolbar option {
    color: #25353a;
    font-weight: 500;
}


/* Bangkok Radar Official v0.4 */

.bangkok-radar-official {
    margin: 8px 0 10px;
    padding: 8px 10px;
    border: 1px solid #b8d8ca;
    border-radius: 8px;
    background: #f2faf6;
}

.bangkok-radar-official-title {
    margin-bottom: 6px;
    font-size: 13px;
    font-weight: 700;
    color: #23483a;
}

.bangkok-radar-official-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.bangkok-radar-official-links a {
    display: inline-block;
    padding: 5px 9px;
    border: 1px solid #a8cdbd;
    border-radius: 6px;
    background: #ffffff;
    color: #174c39;
    font-size: 12px;
    font-weight: 600;
    text-decoration: none;
    white-space: nowrap;
}

.bangkok-radar-official-links a:hover {
    background: #dff2e9;
    border-color: #79af98;
}

@media (max-width: 700px) {
    .bangkok-radar-official-links {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .bangkok-radar-official-links a {
        text-align: center;
        white-space: normal;
    }
}


/* TMD Radar Page Prototype v0.6 */

.radar-tmd-page-shell {
    width: 100%;
    height: 620px;
    min-height: 520px;
    overflow: hidden;
    background: #ffffff;
    border-top: 1px solid #d5e2df;
}

.radar-tmd-page-shell.hidden {
    display: none;
}

.radar-tmd-page-shell iframe {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    background: #ffffff;
}

@media (max-width: 900px) {
    .radar-tmd-page-shell {
        height: 560px;
        min-height: 480px;
    }
}

/* =====================================================
   TMD Official Radar - permanent viewer v0.7
   ===================================================== */

.radar-simple-heading {
    min-height: 34px;
    padding-top: 5px;
    padding-bottom: 5px;
}

.radar-simple-heading h2 {
    margin: 0;
}

.radar-official-viewer {
    width: 100%;
    height: calc(100vh - 205px);
    min-height: 650px;

    overflow-x: hidden;
    overflow-y: auto;

    background: #fff;
}

.radar-official-viewer iframe {
    display: block;

    width: 100%;
    height: 1100px;

    margin: 0;
    padding: 0;
    border: 0;

    background: #fff;
}

@media (max-width: 900px) {
    .radar-official-viewer {
        height: 700px;
        min-height: 600px;
    }
}


/* =====================================================
   Compare 3D Banners v0.8
   ===================================================== */

.compare-3d-banner {
    position: relative;
    box-sizing: border-box;

    display: flex;
    align-items: center;

    min-height: 48px;
    padding: 7px 18px;

    overflow: hidden;

    font-size: 22px;
    line-height: 1.15;
    font-weight: 800;

    color: #ffffff;
    text-shadow:
        0 2px 1px rgba(0, 0, 0, 0.55),
        0 3px 5px rgba(0, 0, 0, 0.28);

    border-radius: 8px 8px 3px 3px;

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.48),
        inset 0 -3px 0 rgba(0, 0, 0, 0.18),
        0 2px 5px rgba(0, 0, 0, 0.20);
}

.compare-3d-banner::after {
    content: "";
    position: absolute;

    top: 0;
    left: 0;
    right: 0;
    height: 48%;

    pointer-events: none;

    background:
        linear-gradient(
            to bottom,
            rgba(255, 255, 255, 0.22),
            rgba(255, 255, 255, 0.02)
        );
}


/* Satellite = TMD blue */

.satellite-3d-banner {
    border: 1px solid #17688f;

    background:
        linear-gradient(
            135deg,
            #073a59 0%,
            #0b628e 50%,
            #148ac0 100%
        );
}


/* Radar = operational green */

.radar-3d-banner {
    border: 1px solid #34784b;

    background:
        linear-gradient(
            135deg,
            #174e2c 0%,
            #287842 52%,
            #45a45e 100%
        );
}


/* Product selector stays compact */

.satellite-panel .product-tabs {
    margin-top: 5px;
}


/* Radar begins immediately below banner */

.radar-official-viewer {
    margin-top: 5px;
}


/* Compact on smaller screens */

@media (max-width: 900px) {

    .compare-3d-banner {
        min-height: 42px;
        padding: 6px 12px;
        font-size: 18px;
    }
}


/* =====================================================
   Compare Graphic Hero Banners v0.9
   ===================================================== */

.compare-hero-banner {
    position: relative;
    box-sizing: border-box;

    height: 72px;
    min-height: 72px;

    display: flex;
    align-items: center;
    justify-content: center;

    overflow: hidden;

    border-radius: 9px 9px 4px 4px;

    box-shadow:
        inset 0 1px 0 rgba(255,255,255,.55),
        inset 0 -4px 0 rgba(0,0,0,.18),
        0 2px 5px rgba(0,0,0,.28);
}


/* ---------- Satellite ---------- */

.satellite-hero-banner {
    border: 1px solid #0b5f98;

    background:
        radial-gradient(
            circle at 23% 105%,
            rgba(76,215,255,.65) 0,
            rgba(20,130,204,.25) 22%,
            transparent 42%
        ),
        linear-gradient(
            110deg,
            #031f48 0%,
            #064d88 43%,
            #087cc1 72%,
            #24a8df 100%
        );
}

.satellite-banner-art {
    position: absolute;
    left: 4px;
    bottom: -7px;

    width: 155px;
    height: 78px;

    filter:
        drop-shadow(0 2px 3px rgba(0,0,0,.5));
}

.satellite-banner-art svg {
    width: 100%;
    height: 100%;
}

.satellite-clouds {
    position: absolute;
    right: -15px;
    bottom: -28px;

    width: 155px;
    height: 70px;

    opacity: .38;

    background:
        radial-gradient(circle at 20% 50%, #fff 0 18%, transparent 20%),
        radial-gradient(circle at 43% 35%, #fff 0 22%, transparent 24%),
        radial-gradient(circle at 67% 55%, #fff 0 25%, transparent 27%),
        radial-gradient(circle at 88% 40%, #fff 0 19%, transparent 21%);
}


/* ---------- Radar ---------- */

.radar-hero-banner {
    border: 1px solid #267b3b;

    background:
        radial-gradient(
            circle at 93% 105%,
            rgba(0,255,50,.55) 0,
            rgba(0,210,35,.15) 25%,
            transparent 43%
        ),
        linear-gradient(
            110deg,
            #06391b 0%,
            #0b6428 48%,
            #07962d 100%
        );
}

.radar-dome-art {
    position: absolute;
    left: 18px;
    bottom: -5px;

    width: 82px;
    height: 72px;

    filter:
        drop-shadow(0 3px 3px rgba(0,0,0,.45));
}

.radar-dome-art svg {
    width: 100%;
    height: 100%;
}

.radar-sweep-art {
    position: absolute;

    right: -20px;
    top: -28px;

    width: 145px;
    height: 145px;

    opacity: .48;

    border: 1px solid rgba(30,255,70,.7);
    border-radius: 50%;

    background:
        repeating-radial-gradient(
            circle,
            transparent 0 16px,
            rgba(34,255,74,.36) 17px 18px
        ),
        conic-gradient(
            from 215deg,
            transparent 0deg 25deg,
            rgba(37,255,75,.70) 26deg 52deg,
            transparent 53deg 360deg
        );
}


/* ---------- Shared text ---------- */

.compare-hero-copy {
    position: relative;
    z-index: 4;

    text-align: center;

    transform: translateY(-1px);
}

.compare-hero-title {
    color: #fff;

    font-size: 27px;
    line-height: 1.05;
    font-weight: 900;

    letter-spacing: .2px;

    text-shadow:
        0 2px 0 rgba(0,0,0,.65),
        0 3px 5px rgba(0,0,0,.45);
}

.satellite-hero-banner .compare-hero-title {
    text-shadow:
        0 2px 0 #073d82,
        0 0 5px rgba(133,222,255,.9),
        0 4px 5px rgba(0,0,0,.55);
}

.radar-hero-banner .compare-hero-title {
    text-shadow:
        0 2px 0 #06481a,
        0 0 5px rgba(163,255,173,.55),
        0 4px 5px rgba(0,0,0,.55);
}

.compare-hero-en {
    margin-top: 5px;

    color: rgba(255,255,255,.94);

    font-family: Arial, sans-serif;
    font-size: 10px;
    line-height: 1;
    font-weight: 700;

    letter-spacing: 4px;

    text-shadow:
        0 1px 2px rgba(0,0,0,.7);
}


/* Product menu immediately under satellite banner */

.satellite-panel .product-tabs {
    margin-top: 5px;
}


/* TMD Radar immediately under radar banner */

.radar-official-viewer {
    margin-top: 5px;
}


/* ---------- Responsive ---------- */

@media (max-width: 900px) {

    .compare-hero-banner {
        height: 62px;
        min-height: 62px;
    }

    .compare-hero-title {
        font-size: 21px;
    }

    .compare-hero-en {
        margin-top: 3px;
        font-size: 8px;
        letter-spacing: 2.5px;
    }

    .satellite-banner-art {
        width: 115px;
    }

    .radar-dome-art {
        left: 8px;
        width: 65px;
    }

    .radar-sweep-art {
        width: 110px;
        height: 110px;
    }
}

/* =========================================================
   SATAID Web Compare - Real Artwork Banners
   ========================================================= */

.compare-photo-banner {
    position: relative;
    width: 100%;
    height: 82px;
    flex: 0 0 82px;
    overflow: hidden;
    border-radius: 8px 8px 0 0;

    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;

    display: flex;
    align-items: center;
    justify-content: center;

    box-shadow:
        inset 0 -1px 0 rgba(255,255,255,.18),
        0 2px 5px rgba(15,23,42,.18);
}

/* Satellite artwork */
.satellite-photo-banner {
    background-image:
        linear-gradient(
            90deg,
            rgba(0,20,55,.08) 0%,
            rgba(0,25,65,.10) 35%,
            rgba(0,18,48,.22) 100%
        ),
        url("../banners/satellite-banner.png");

    background-position: center center;
}

/* Radar artwork */
.radar-photo-banner {
    background-image:
        linear-gradient(
            90deg,
            rgba(0,45,30,.06) 0%,
            rgba(0,40,28,.08) 45%,
            rgba(0,35,25,.18) 100%
        ),
        url("../banners/radar-banner.png");

    background-position: center center;
}

/* Banner text */
.compare-photo-copy {
    position: relative;
    z-index: 2;
    text-align: center;
    line-height: 1.05;
    pointer-events: none;

    padding: 5px 22px 4px;

    text-shadow:
        0 2px 2px rgba(0,0,0,.70),
        0 4px 10px rgba(0,0,0,.45);
}

.compare-photo-title {
    color: #ffffff;
    font-size: 23px;
    font-weight: 800;
    letter-spacing: .2px;
}

.compare-photo-en {
    margin-top: 7px;

    color: rgba(255,255,255,.94);
    font-size: 10px;
    font-weight: 700;

    letter-spacing: 3px;
}

/* Compact layout */
@media (max-width: 900px) {
    .compare-photo-banner {
        height: 74px;
        flex-basis: 74px;
    }

    .compare-photo-title {
        font-size: 20px;
    }

    .compare-photo-en {
        font-size: 9px;
        letter-spacing: 2.4px;
    }
}

