/* ========== Theme variables ========== */

:root {
    --bg: #fbfcfe;
    --panel: #ffffff;
    --muted: #6b7280;
    --text: #0f172a;
    --primary: #0f62ff;
    /* fresh blue */
    --glass: rgba(15, 23, 42, 0.03);
    --radius: 14px;
    --card-h: 132px;
    --shadow: 0 6px 22px rgba(12, 22, 60, 0.08);
}

body.dark {
    --bg: #0b0d11;
    --panel: #0f1418;
    --muted: #9aa4b2;
    --text: #e6eef8;
    --primary: #7da3ff;
    --glass: rgba(255, 255, 255, 0.02);
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}


/* ========== Base ========== */

* {
    box-sizing: border-box
}

html,
body {
    height: 100%
}

body {
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial;
    background: radial-gradient(circle at 10% 10%, rgba(15, 23, 42, 0.02) 1px, transparent 1px), var(--bg);
    background-size: 18px 18px;
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background .28s ease, color .28s ease;
}


/* ========== Header ========== */

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 64px;
    display: flex;
    align-items: center;
    backdrop-filter: blur(6px) saturate(120%);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.45));
    border-bottom: 1px solid rgba(15, 23, 42, 0.04);
    z-index: 40;
}

body.dark .site-header {
    background: linear-gradient(180deg, rgba(16, 20, 24, 0.6), rgba(16, 20, 24, 0.45));
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

.header-inner {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.brand .brand-name {
    font-weight: 600;
    font-size: 16px;
    letter-spacing: 0.1px;
}

.brand .brand-sub {
    font-size: 12px;
    color: var(--muted);
    margin-top: 4px;
}


/* theme icon button */

.icon-btn {
    height: 40px;
    width: 40px;
    border-radius: 10px;
    border: 0;
    background: var(--panel);
    box-shadow: var(--shadow);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
}

.icon-btn:hover {
    transform: translateY(-2px);
}


/* ========== Main / Hero ========== */

.page {
    padding-top: 112px
}

.hero {
    max-width: 1200px;
    margin: 18px auto 8px;
    padding: 26px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.6), rgba(255, 255, 255, 0.35));
    border-radius: 18px;
    box-shadow: var(--shadow);
    border: 1px solid rgba(15, 23, 42, 0.03);
}

body.dark .hero {
    background: linear-gradient(180deg, rgba(16, 20, 24, 0.5), rgba(16, 20, 24, 0.35));
}

.hero-inner {
    max-width: 78%
}

.hero-title {
    margin: 0;
    font-size: 28px;
    font-weight: 700;
    letter-spacing: -0.3px;
}

.hero-sub {
    margin: 8px 0 0;
    color: var(--muted);
    font-size: 13.5px;
}

.group-title {
    font-size: 19px;
    font-weight: 600;
    color: var(--primary);
    margin: 40px 0 12px;
    padding-top: 18px;
    border-top: 1px dashed var(--border);
}


/* floating control (right) */

.floating-controls {
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
}


/* segmented control */

.segmented {
    position: relative;
    background: var(--panel);
    border-radius: 10px;
    padding: 4px;
    display: flex;
    border: 1px solid rgba(15, 23, 42, 0.04);
    box-shadow: 0 6px 18px rgba(12, 22, 60, 0.04);
}

.segmented .seg-btn {
    border: 0;
    background: transparent;
    padding: 8px 18px;
    border-radius: 8px;
    font-weight: 600;
    color: var(--muted);
    cursor: pointer;
    position: relative;
    z-index: 2;
}

.segmented .seg-btn.active {
    color: #fff
}

.segmented .seg-highlight {
    position: absolute;
    left: 4px;
    top: 4px;
    width: calc(50% - 8px);
    height: calc(100% - 8px);
    background: var(--primary);
    border-radius: 8px;
    z-index: 1;
    transition: transform .28s cubic-bezier(.2, .9, .3, 1);
}


/* move highlight when list active */

.segmented.list-active .seg-highlight {
    transform: translateX(100%);
}


/* ========== Tools container ========== */

.tools-wrap {
    max-width: 1200px;
    margin: 18px auto 80px;
    padding: 18px;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.02), transparent);
    border-radius: 16px;
    border: 1px solid rgba(15, 23, 42, 0.02);
}


/* grid */

.container {
    padding: 8px
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 18px;
}

.card {
    height: var(--card-h);
    background: var(--panel);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 12px;
    box-shadow: 0 8px 30px rgba(12, 22, 60, 0.04);
    border: 1px solid rgba(15, 23, 42, 0.03);
    cursor: pointer;
    transition: transform .18s ease, box-shadow .18s ease;
}

.card:hover {
    transform: translateY(-0.5px);
    box-shadow: 0 12px 40px rgba(12, 22, 60, 0.08);
}

.card svg {
    stroke: var(--primary);
    width: 42px;
    height: 42px;
    margin-bottom: 8px;
    display: block;
    border-radius: 8px;
}

.card .title {
    font-weight: 600;
    font-size: 14px;
    color: var(--text);
    line-height: 1.25;
    max-width: 100%;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden
}


/* list */

.list-mode {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 10px
}

.list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    background: var(--panel);
    padding: 12px 14px;
    border-radius: 10px;
    box-shadow: 0 8px 30px rgba(12, 22, 60, 0.03);
    border: 1px solid rgba(15, 23, 42, 0.03);
    cursor: pointer;
    /* <<< penting */
    transition: transform .18s ease, box-shadow .18s ease;
    /* <<< sama seperti .card */
}

.list-item:hover {
    transform: translateY(-4px) scale(1.02);
    box-shadow: 0 12px 40px rgba(12, 22, 60, 0.08);
}

.list-item svg {
    width: 36px;
    height: 36px;
    display: block
}

.list-item .title {
    font-weight: 600;
    font-size: 15px;
    color: var(--text)
}


/* footer */

.site-footer {
    text-align: center;
    padding: 28px 12px 60px;
    color: var(--muted)
}

.site-footer small {
    display: block;
    margin-top: 6px;
    font-size: 13px;
    color: var(--muted)
}


/* responsive */

@media (max-width:900px) {
    .hero {
        flex-direction: column;
        align-items: flex-start;
        gap: 14px
    }
    .hero-inner {
        max-width: 100%
    }
    .floating-controls {
        align-self: flex-end
    }
    .tools-wrap {
        padding: 12px
    }
}

@media (max-width:520px) {
    .hero-title {
        font-size: 20px
    }
    .card {
        height: 120px
    }
}