* {
    box-sizing: border-box;
}

:root {
    color-scheme: dark;
    --page-bg: #061325;
    --page-bg-soft: #0a1a2f;
    --hero-start: #0878bf;
    --hero-end: #07538f;
    --hero-text: #ffffff;
    --surface: #0d1d33;
    --surface-2: #122640;
    --surface-3: #172d49;
    --text: #f7f9fc;
    --muted: #9eb2cd;
    --line: rgba(164, 193, 226, 0.18);
    --line-strong: rgba(164, 193, 226, 0.30);
    --primary: #168fe2;
    --primary-hover: #2da5f4;
    --accent: #ffd21c;
    --accent-hover: #ffe05c;
    --accent-text: #04111f;
    --success: #36d399;
    --danger: #ff6b78;
    --footer-bg: #071426;
    --brand-pill: #050d1c;
    --shadow: 0 24px 70px rgba(0, 0, 0, 0.34);
    --soft-shadow: 0 14px 40px rgba(0, 0, 0, 0.22);
}

html[data-theme="light"] {
    color-scheme: light;
    --page-bg: #eef5fb;
    --page-bg-soft: #f7fbff;
    --hero-start: #1387cc;
    --hero-end: #0865a5;
    --surface: #ffffff;
    --surface-2: #f5f9fd;
    --surface-3: #eaf3fb;
    --text: #10243a;
    --muted: #61758d;
    --line: rgba(38, 85, 126, 0.14);
    --line-strong: rgba(38, 85, 126, 0.24);
    --primary: #087ac3;
    --primary-hover: #096aa7;
    --accent: #ffd21c;
    --accent-hover: #f5c300;
    --accent-text: #071421;
    --success: #0c9d6a;
    --danger: #d83a4b;
    --footer-bg: #e5eff8;
    --brand-pill: #061326;
    --shadow: 0 24px 65px rgba(38, 84, 125, 0.15);
    --soft-shadow: 0 12px 36px rgba(38, 84, 125, 0.12);
}

html {
    min-height: 100%;
    scroll-behavior: smooth;
    background: var(--page-bg);
}

body {
    min-width: 320px;
    min-height: 100vh;
    margin: 0;
    overflow-x: hidden;
    color: var(--text);
    background:
        radial-gradient(circle at 12% 22%, rgba(28, 149, 231, 0.08), transparent 28rem),
        linear-gradient(180deg, var(--page-bg-soft), var(--page-bg));
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    transition: color .25s ease, background-color .25s ease;
}

button,
input {
    font: inherit;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    cursor: pointer;
}

.site-shell {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.hero {
    position: relative;
    min-height: 440px;
    overflow: hidden;
    border-radius: 0 0 34px 34px;
    color: var(--hero-text);
    background: linear-gradient(135deg, var(--hero-start), var(--hero-end));
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.13);
}

.hero::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background:
        linear-gradient(115deg, rgba(255, 255, 255, 0.04), transparent 34%),
        radial-gradient(circle at 50% 105%, rgba(0, 26, 58, 0.16), transparent 38%);
}

.topbar {
    position: relative;
    z-index: 3;
    width: min(100%, 1600px);
    margin: 0 auto;
    padding: 25px 28px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.brand-link {
    min-height: 52px;
    display: inline-flex;
    align-items: center;
    gap: 11px;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    padding: 7px 18px 7px 9px;
    color: #ffffff;
    background: var(--brand-pill);
    box-shadow: 0 12px 30px rgba(0, 0, 0, 0.20);
    text-decoration: none;
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.brand-link:hover {
    transform: translateY(-1px);
    border-color: rgba(78, 175, 255, 0.55);
    box-shadow: 0 16px 34px rgba(0, 0, 0, 0.26);
}

.brand-logo-wrap {
    width: 36px;
    height: 36px;
    display: grid;
    place-items: center;
    overflow: hidden;
    border-radius: 10px;
    background: radial-gradient(circle, rgba(23, 104, 176, 0.30), rgba(1, 8, 18, 0.78));
}

.brand-logo {
    width: 34px;
    height: 34px;
    object-fit: contain;
    display: block;
}

.brand-name {
    font-size: 14px;
    font-weight: 900;
    letter-spacing: .16em;
    white-space: nowrap;
}

.theme-toggle {
    min-width: 72px;
    height: 39px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    border-radius: 999px;
    padding: 4px 7px;
    color: #ffffff;
    background: rgba(5, 30, 58, 0.54);
    box-shadow: 0 10px 24px rgba(0, 0, 0, 0.16);
    backdrop-filter: blur(8px);
}

.theme-icon {
    width: 14px;
    font-size: 13px;
    line-height: 1;
    text-align: center;
    opacity: .58;
    transition: opacity .2s ease, transform .2s ease;
}

.theme-switch-track {
    position: relative;
    width: 31px;
    height: 22px;
    border-radius: 999px;
    background: rgba(2, 15, 31, 0.58);
}

.theme-switch-knob {
    position: absolute;
    top: 3px;
    left: 3px;
    width: 16px;
    height: 16px;
    border-radius: 50%;
    background: #dcecff;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.25);
    transition: transform .24s ease, background .24s ease;
}

html[data-theme="light"] .theme-switch-knob {
    transform: translateX(9px);
    background: var(--accent);
}

html[data-theme="dark"] .theme-icon-moon,
html[data-theme="light"] .theme-icon-sun {
    opacity: 1;
    transform: scale(1.08);
}

.hero-content {
    position: relative;
    z-index: 2;
    width: min(100% - 36px, 780px);
    margin: 3px auto 0;
    text-align: center;
}

.hero-kicker,
.section-kicker {
    margin: 0 0 11px;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .22em;
}

.hero-kicker {
    color: rgba(225, 242, 255, 0.78);
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 13px;
    font-size: clamp(36px, 5vw, 58px);
    line-height: 1.04;
    letter-spacing: -.045em;
}

.hero-subtitle {
    width: min(100%, 610px);
    margin: 0 auto;
    color: rgba(246, 251, 255, 0.92);
    font-size: clamp(15px, 2vw, 18px);
    line-height: 1.65;
}

.hero-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 20px;
}

.hero-action {
    min-width: 118px;
    min-height: 46px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(255, 255, 255, 0.26);
    border-radius: 999px;
    padding: 0 24px;
    color: #ffffff;
    background: rgba(3, 25, 50, 0.20);
    box-shadow: none;
    font-size: 14px;
    font-weight: 900;
    text-decoration: none;
    transition: transform .16s ease, background .18s ease, color .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.hero-action:hover {
    transform: translateY(-1px);
    background: rgba(255, 255, 255, 0.15);
}

.hero-action.active {
    border-color: var(--accent);
    color: var(--accent-text);
    background: var(--accent);
    box-shadow: 0 12px 24px rgba(7, 34, 64, 0.24);
}

.hero-action.active:hover {
    background: var(--accent-hover);
}

.hero-decoration {
    position: absolute;
    z-index: 1;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
    pointer-events: none;
}

.hero-decoration-left {
    width: 310px;
    height: 310px;
    top: -170px;
    left: -120px;
}

.hero-decoration-right {
    width: 280px;
    height: 280px;
    right: -120px;
    bottom: -185px;
}

.content-wrap {
    position: relative;
    z-index: 5;
    width: min(100% - 34px, 920px);
    margin: -80px auto 0;
    flex: 1 0 auto;
}

.checker-card,
.result-section,
.privacy-note {
    border: 1px solid var(--line);
    background: var(--surface);
    box-shadow: var(--shadow);
}

.checker-card {
    border-radius: 24px;
    padding: 27px 28px 24px;
}

.quota-form label {
    display: inline-block;
    margin-bottom: 12px;
    color: var(--text);
    font-size: 14px;
    font-weight: 850;
}

.input-row {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 12px;
}

.phone-input-wrap {
    position: relative;
    min-width: 0;
}

.phone-icon {
    position: absolute;
    top: 50%;
    left: 17px;
    z-index: 2;
    color: var(--muted);
    font-size: 17px;
    transform: translateY(-50%);
    pointer-events: none;
}

input {
    width: 100%;
    min-width: 0;
    height: 58px;
    border: 1px solid var(--line-strong);
    border-radius: 17px;
    padding: 0 18px 0 47px;
    color: var(--text);
    background: var(--surface-2);
    outline: none;
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.02);
    font-size: 16px;
    transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}

input::placeholder {
    color: var(--muted);
    opacity: .78;
}

input:focus {
    border-color: var(--primary);
    background: var(--surface-3);
    box-shadow: 0 0 0 4px rgba(22, 143, 226, 0.15);
}

#checkButton {
    min-width: 152px;
    height: 58px;
    border: 0;
    border-radius: 17px;
    padding: 0 24px;
    color: var(--accent-text);
    background: var(--accent);
    box-shadow: 0 10px 22px rgba(5, 27, 52, 0.16);
    font-weight: 900;
    transition: transform .15s ease, background .2s ease, opacity .2s ease;
}

#checkButton:hover {
    transform: translateY(-1px);
    background: var(--accent-hover);
}

#checkButton:active {
    transform: translateY(1px);
}

#checkButton:disabled {
    cursor: wait;
    opacity: .72;
}

.spinner {
    display: none;
    width: 19px;
    height: 19px;
    margin: auto;
    border: 2px solid rgba(5, 17, 31, 0.30);
    border-top-color: var(--accent-text);
    border-radius: 999px;
    animation: spin .8s linear infinite;
}

#checkButton.loading .button-text {
    display: none;
}

#checkButton.loading .spinner {
    display: block;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.form-notes {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 12px;
}

.help-text,
.auto-note {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.auto-note {
    text-align: right;
}

.alert {
    margin-top: 18px;
    border: 1px solid rgba(255, 107, 120, 0.38);
    border-radius: 16px;
    padding: 14px 16px;
    color: var(--danger);
    background: color-mix(in srgb, var(--danger) 10%, var(--surface));
    box-shadow: var(--soft-shadow);
    line-height: 1.55;
}

.result-section {
    margin-top: 24px;
    border-radius: 24px;
    padding: 28px;
}

.result-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 18px;
}

.section-kicker {
    margin-bottom: 7px;
    color: var(--primary);
}

h2 {
    margin-bottom: 0;
    font-size: clamp(21px, 3vw, 28px);
    line-height: 1.2;
    letter-spacing: -.025em;
}

.copy-button {
    flex: 0 0 auto;
    min-height: 45px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid color-mix(in srgb, var(--primary) 52%, transparent);
    border-radius: 14px;
    padding: 0 17px;
    color: var(--text);
    background: color-mix(in srgb, var(--primary) 10%, var(--surface));
    font-weight: 850;
    transition: transform .15s ease, background .18s ease, border-color .18s ease;
}

.copy-button:hover {
    transform: translateY(-1px);
    background: color-mix(in srgb, var(--primary) 16%, var(--surface));
}

.copy-button.copied {
    border-color: color-mix(in srgb, var(--success) 55%, transparent);
    color: var(--success);
    background: color-mix(in srgb, var(--success) 11%, var(--surface));
}

.copy-icon {
    font-size: 14px;
}

.formatted-result {
    max-width: 100%;
    min-height: 120px;
    margin: 0;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: clamp(18px, 3vw, 25px);
    color: var(--text);
    background: var(--surface-2);
    box-shadow: inset 0 1px rgba(255, 255, 255, 0.02);
    font: 500 14px/1.7 ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
}


.privacy-note {
    margin: 18px 0 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    border-radius: 16px;
    padding: 13px 16px;
    box-shadow: var(--soft-shadow);
}

.privacy-note p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
    text-align: center;
}

.privacy-icon {
    flex: 0 0 auto;
    width: 22px;
    height: 22px;
    display: grid;
    place-items: center;
    border-radius: 50%;
    color: #ffffff;
    background: var(--success);
    font-size: 12px;
    font-weight: 900;
}

.site-footer {
    flex: 0 0 auto;
    border-top: 1px solid var(--line);
    padding: 17px 18px;
    color: var(--muted);
    background: var(--footer-bg);
    text-align: center;
}

.site-footer p {
    margin-bottom: 0;
    font-size: 12px;
}

.site-footer a {
    color: var(--text);
    font-weight: 900;
    text-decoration: none;
}

.site-footer a:hover {
    color: var(--primary);
}

@media (max-width: 720px) {
    .hero {
        min-height: 455px;
        border-radius: 0 0 28px 28px;
    }

    .topbar {
        padding: 17px 16px;
    }

    .brand-link {
        min-height: 46px;
        gap: 8px;
        padding: 6px 12px 6px 7px;
    }

    .brand-logo-wrap {
        width: 32px;
        height: 32px;
    }

    .brand-logo {
        width: 30px;
        height: 30px;
    }

    .brand-name {
        font-size: 11px;
        letter-spacing: .12em;
    }

    .theme-toggle {
        min-width: 64px;
    }

    .hero-content {
        margin-top: 25px;
    }

    h1 {
        font-size: clamp(35px, 11vw, 48px);
    }

    .hero-subtitle {
        font-size: 15px;
    }

    .hero-actions {
        gap: 10px;
    }

    .hero-action {
        min-width: 112px;
        padding: 0 20px;
    }

    .content-wrap {
        width: min(100% - 24px, 920px);
        margin-top: -82px;
    }

    .checker-card,
    .result-section {
        border-radius: 20px;
        padding: 20px 16px;
    }

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

    #checkButton {
        width: 100%;
    }

    .form-notes {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .auto-note {
        text-align: left;
    }

    .result-heading {
        align-items: flex-start;
    }

    .copy-button {
        padding: 0 13px;
    }

    .formatted-result {
        font-size: 12px;
        line-height: 1.65;
    }
}

@media (max-width: 430px) {
    .brand-name {
        max-width: 125px;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .hero {
        min-height: 470px;
    }

    .hero-content {
        width: calc(100% - 28px);
    }

    .result-heading {
        flex-direction: column;
    }

    .copy-button {
        width: 100%;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
    }
}


/* v1.3.0 — Cek Kuota dan Cek Area dalam satu domain */
.service-panel[hidden] {
    display: none !important;
}

.service-tab {
    font-family: inherit;
    cursor: pointer;
}

.area-panel {
    padding-bottom: 34px;
}

.area-search-card {
    position: relative;
}

.area-search-label {
    display: inline-block;
    margin-bottom: 12px;
    color: var(--text);
    font-size: 14px;
    font-weight: 850;
}

.area-search-box {
    position: relative;
}

.area-search-box input {
    height: 58px;
    padding: 0 54px 0 47px;
}

.area-search-icon {
    position: absolute;
    top: 50%;
    left: 17px;
    z-index: 2;
    color: var(--muted);
    font-size: 22px;
    line-height: 1;
    transform: translateY(-52%);
    pointer-events: none;
}

.area-clear-button {
    position: absolute;
    top: 50%;
    right: 12px;
    z-index: 2;
    width: 34px;
    height: 34px;
    display: grid;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    padding: 0 0 2px;
    color: var(--muted);
    background: var(--surface-3);
    font-size: 22px;
    line-height: 1;
    transform: translateY(-50%);
}

.area-clear-button:hover {
    color: var(--text);
    border-color: var(--line-strong);
}

.area-form-notes {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-top: 12px;
}

.area-result-info,
.area-hint {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 12px;
    line-height: 1.5;
}

.area-hint {
    text-align: right;
}

.area-results-section {
    margin-top: 18px;
}

.area-table-head {
    display: grid;
    grid-template-columns: minmax(190px, 220px) minmax(0, 1fr) 146px;
    gap: 12px;
    padding: 14px 22px;
    color: color-mix(in srgb, var(--primary) 68%, var(--text));
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.area-results {
    display: grid;
    gap: 12px;
}

.area-result-card {
    display: grid;
    grid-template-columns: minmax(190px, 220px) minmax(0, 1fr) 146px;
    align-items: center;
    gap: 12px;
    min-height: 82px;
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 20px 22px;
    background: linear-gradient(180deg, var(--surface-3), var(--surface-2));
    box-shadow: var(--soft-shadow);
    animation: areaCardIn .22s ease both;
}

@keyframes areaCardIn {
    from { opacity: 0; transform: translateY(7px); }
    to { opacity: 1; transform: translateY(0); }
}

.area-province {
    color: var(--text);
    font-size: 17px;
    font-weight: 900;
    line-height: 1.35;
}

.area-cities {
    color: var(--muted);
    font-size: 14px;
    line-height: 1.52;
}

.area-actions {
    justify-self: start;
    display: inline-flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    min-width: 0;
}

.area-badge {
    min-width: 76px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    padding: 10px 12px;
    color: #ffffff;
    background: linear-gradient(180deg, var(--primary-hover), var(--primary));
    box-shadow: 0 8px 20px rgba(6, 115, 199, .24);
    font-size: 13px;
    font-weight: 900;
    white-space: nowrap;
}

.area-copy-button {
    width: 38px;
    height: 38px;
    flex: 0 0 38px;
    display: inline-grid;
    place-items: center;
    border: 1px solid var(--line-strong);
    border-radius: 10px;
    padding: 0;
    color: var(--muted);
    background: var(--surface-3);
    cursor: pointer;
    transition:
        color .18s ease,
        border-color .18s ease,
        background .18s ease,
        transform .18s ease;
}

.area-copy-button:hover {
    color: var(--text);
    border-color: color-mix(in srgb, var(--primary) 66%, var(--line));
    background: color-mix(in srgb, var(--primary) 12%, var(--surface-3));
    transform: translateY(-1px);
}

.area-copy-button:focus-visible {
    outline: 3px solid color-mix(in srgb, var(--primary) 28%, transparent);
    outline-offset: 2px;
}

.area-copy-button.copied {
    color: #ffffff;
    border-color: #16b878;
    background: #16b878;
}

.area-copy-button svg {
    width: 18px;
    height: 18px;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

mark {
    border-radius: 4px;
    padding: 0 3px;
    color: var(--accent-text);
    background: var(--accent);
}

.area-empty-state {
    margin-top: 14px;
}

.area-empty-card {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 34px 24px;
    color: var(--muted);
    background:
        radial-gradient(circle at top left, color-mix(in srgb, var(--accent) 10%, transparent), transparent 34%),
        linear-gradient(180deg, var(--surface-3), var(--surface));
    box-shadow: var(--soft-shadow);
    text-align: center;
}

.area-empty-icon {
    font-size: 31px;
}

.area-empty-kicker {
    margin: 10px 0 8px;
    color: var(--primary);
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.area-empty-card h2 {
    max-width: 680px;
    margin: 0 auto 9px;
    color: var(--text);
}

.area-empty-card > p:last-of-type {
    max-width: 560px;
    margin: 0 auto;
    line-height: 1.6;
}

#emptyQuery {
    color: var(--accent);
}

.area-quick-searches {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 9px;
    margin: 21px auto 17px;
}

.area-quick-searches button,
.area-show-all {
    border-radius: 999px;
    cursor: pointer;
    font-weight: 850;
    transition: transform .18s ease, background .18s ease, border-color .18s ease;
}

.area-quick-searches button {
    border: 1px solid var(--line);
    padding: 9px 13px;
    color: var(--text);
    background: var(--surface-2);
}

.area-show-all {
    border: 0;
    padding: 12px 18px;
    color: var(--accent-text);
    background: var(--accent);
}

.area-quick-searches button:hover,
.area-show-all:hover {
    transform: translateY(-1px);
}

@media (max-width: 720px) {
    .area-form-notes {
        align-items: flex-start;
        flex-direction: column;
        gap: 5px;
    }

    .area-hint {
        text-align: left;
    }

    .area-table-head {
        display: none;
    }

    .area-results-section {
        margin-top: 14px;
    }

    .area-result-card {
        grid-template-columns: 1fr;
        gap: 9px;
        padding: 19px 17px;
    }

    .area-actions {
        justify-self: start;
    }

    .area-empty-card {
        padding: 29px 17px;
    }
}

@media (max-width: 430px) {
    .hero-actions {
        width: 100%;
        flex-wrap: nowrap;
    }

    .hero-action {
        min-width: 0;
        flex: 1 1 0;
        padding: 0 14px;
    }
}
