﻿:root {
    --bg: #0f1117;
    --bg-accent: #151923;
    --surface: #171b25;
    --surface-strong: #1a1f2b;
    --surface-soft: #1f2533;
    --surface-glass: rgba(26, 31, 43, 0.78);
    --line: rgba(148, 163, 184, 0.16);
    --line-strong: rgba(148, 163, 184, 0.24);
    --text: #f8fafc;
    --text-soft: #cbd5e1;
    --text-muted: #94a3b8;
    --primary: #2dd4a8;
    --primary-strong: #14b88a;
    --primary-soft: rgba(45, 212, 168, 0.14);
    --primary-glow: rgba(45, 212, 168, 0.28);
    --danger: #fb7185;
    --danger-soft: rgba(251, 113, 133, 0.14);
    --warning: #fbbf24;
    --shadow-lg: 0 28px 80px rgba(3, 7, 18, 0.48);
    --shadow-md: 0 20px 48px rgba(3, 7, 18, 0.32);
    --shadow-sm: 0 14px 24px rgba(15, 23, 42, 0.22);
    --radius-lg: 20px;
    --radius-md: 16px;
    --radius-sm: 12px;
    --sidebar-width: 248px;
    --content-max: 1380px;
}

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-width: 1024px;
    margin: 0;
    font-family: "Inter", "Noto Sans KR", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(45, 212, 168, 0.08), transparent 26%),
        radial-gradient(circle at top right, rgba(59, 130, 246, 0.08), transparent 28%),
        linear-gradient(180deg, #0f1117 0%, #0a0c12 100%);
    min-height: 100vh;
}

body.drawer-open {
    overflow: hidden;
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
}

button,
input,
select,
textarea {
    font: inherit;
}

button {
    border: 0;
}

textarea {
    resize: vertical;
}

code,
textarea[readonly] {
    font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
}

.app-shell {
    min-height: 100vh;
}

.drawer-overlay {
    position: fixed;
    inset: 0;
    background: rgba(2, 6, 23, 0.68);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.28s ease, visibility 0.28s ease;
    z-index: 40;
}

body.drawer-open .drawer-overlay {
    opacity: 1;
    visibility: visible;
}

.drawer-toggle,
.drawer-close,
.btn-reset {
    appearance: none;
    background: transparent;
    border: 0;
    padding: 0;
    color: inherit;
}

.drawer-toggle {
    position: fixed;
    top: 18px;
    right: 18px;
    z-index: 60;
    width: 48px;
    height: 48px;
    display: none;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: rgba(15, 23, 42, 0.9);
    border: 1px solid var(--line);
    box-shadow: var(--shadow-sm);
    color: var(--text);
}

.drawer-close {
    display: none;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    align-items: center;
    justify-content: center;
    color: var(--text-soft);
}

.app-sidebar {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: var(--sidebar-width);
    padding: 20px 18px;
    z-index: 50;
}

.app-sidebar-inner {
    height: 100%;
    display: flex;
    flex-direction: column;
    gap: 24px;
    background: linear-gradient(180deg, rgba(23, 27, 37, 0.96), rgba(17, 21, 30, 0.96));
    border: 1px solid var(--line);
    border-radius: 28px;
    box-shadow: var(--shadow-lg);
    backdrop-filter: blur(18px);
    padding: 22px 18px;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 14px;
    min-width: 0;
}

.brand-mark {
    width: 46px;
    height: 46px;
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    font-weight: 800;
    color: #052e2b;
    background: linear-gradient(135deg, #67f7d4, #2dd4a8 55%, #0ea5a4);
    box-shadow: 0 14px 28px rgba(45, 212, 168, 0.25);
}

.brand-copy {
    display: grid;
    gap: 3px;
}

.brand-title {
    font-weight: 700;
    letter-spacing: -0.03em;
}

.brand-subtitle {
    color: var(--text-muted);
    font-size: 0.82rem;
}

.sidebar-nav {
    display: grid;
    gap: 8px;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    color: var(--text-soft);
    border: 1px solid transparent;
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}

.nav-link:hover,
.nav-link:focus-visible {
    color: var(--text);
    background: rgba(255, 255, 255, 0.04);
    border-color: var(--line);
    transform: translateX(2px);
}

.nav-link.is-active {
    background: linear-gradient(180deg, rgba(45, 212, 168, 0.18), rgba(45, 212, 168, 0.08));
    border-color: rgba(45, 212, 168, 0.24);
    color: var(--text);
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.nav-link-danger {
    color: #fecdd3;
}

.nav-link-icon {
    width: 20px;
    height: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 20px;
}

.nav-link-icon svg,
.drawer-toggle svg,
.drawer-close svg,
.search-field svg,
.stat-icon svg,
.empty-icon svg,
.bookmark-inline-icon svg {
    width: 100%;
    height: 100%;
}

.sidebar-meta {
    margin-top: auto;
    display: grid;
    gap: 16px;
}

.logout-form {
    margin: 0;
}

.logout-form .nav-link {
    width: 100%;
    justify-content: center;
}

.sidebar-user {
    padding: 16px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--line);
}

.user-label {
    color: var(--text-muted);
    font-size: 0.8rem;
    margin-bottom: 6px;
}

.user-value {
    font-size: 0.95rem;
    font-weight: 600;
    word-break: break-word;
}

.content-shell {
    margin-left: calc(var(--sidebar-width) + 20px);
    min-height: 100vh;
    padding: 28px 28px 40px;
}

.content-inner {
    max-width: var(--content-max);
    margin: 0 auto;
}

.page-topbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.page-kicker {
    color: var(--primary);
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.18em;
    margin-bottom: 8px;
}

.auth-brand-kicker {
    font-size: 1.12rem;
    letter-spacing: 0.12em;
    margin-bottom: 18px;
}

.page-heading {
    font-size: clamp(1.8rem, 2vw, 2.35rem);
    line-height: 1.02;
    margin: 0;
    letter-spacing: -0.04em;
}

.page-subheading {
    margin: 10px 0 0;
    color: var(--text-muted);
}

.page-meta-badge {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--line);
    color: var(--text-soft);
    white-space: nowrap;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 999px;
    background: var(--primary);
    box-shadow: 0 0 0 6px rgba(45, 212, 168, 0.12);
}

.page-shell {
    display: grid;
    gap: 18px;
}

.standalone-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

.panel,
.panel-soft {
    position: relative;
    background: linear-gradient(180deg, rgba(23, 27, 37, 0.98), rgba(17, 21, 30, 0.98));
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    padding: 24px;
    overflow: hidden;
}

.panel::before,
.panel-soft::before,
.glass-panel::before {
    content: "";
    position: absolute;
    inset: 0 auto auto 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.16), transparent);
}

.panel-soft {
    background: linear-gradient(180deg, rgba(31, 37, 51, 0.98), rgba(23, 27, 37, 0.98));
}

.glass-panel {
    background: linear-gradient(180deg, rgba(20, 24, 33, 0.88), rgba(15, 18, 26, 0.82));
    backdrop-filter: blur(14px);
}

.narrow {
    max-width: 560px;
    margin: 0 auto;
    width: 100%;
}

.section-head,
.button-row,
.inline-group,
.checkbox-row,
.toolbar-grid,
.bookmark-actions,
.filter-pill-row,
.tag-row,
.pagination {
    display: flex;
    gap: 12px;
}

.section-head {
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 22px;
    flex-wrap: wrap;
}

.section-head h1,
.section-head h2,
.section-head h3,
.auth-card h1,
.panel h1,
.panel h2,
.panel-soft h2 {
    margin: 0;
    letter-spacing: -0.04em;
}

.section-head p,
.auth-copy,
.panel p,
.panel-soft p {
    margin-top: 10px;
}

.stack-form {
    display: grid;
    gap: 16px;
}

.stack-form label {
    display: grid;
    gap: 8px;
    color: var(--text-soft);
    font-size: 0.95rem;
}

.stack-form label > span {
    font-weight: 600;
    color: var(--text-soft);
}

.grid {
    display: grid;
    gap: 16px;
}

.two-col {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.full {
    grid-column: 1 / -1;
}

input,
select,
textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 16px;
    padding: 13px 15px;
    background: rgba(15, 23, 42, 0.64);
    color: var(--text);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

input::placeholder,
textarea::placeholder {
    color: rgba(148, 163, 184, 0.72);
}

input:focus,
select:focus,
textarea:focus {
    outline: none;
    border-color: rgba(45, 212, 168, 0.55);
    box-shadow: 0 0 0 4px rgba(45, 212, 168, 0.12), 0 12px 30px rgba(13, 17, 23, 0.26);
    background: rgba(15, 23, 42, 0.92);
}

input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--primary);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 11px 16px;
    border-radius: 15px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.04);
    color: var(--text);
    cursor: pointer;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.btn:hover,
.btn:focus-visible {
    transform: translateY(-1px);
    border-color: var(--line-strong);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.18);
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-strong) 100%);
    color: #04241f;
    border-color: rgba(45, 212, 168, 0.54);
    box-shadow: 0 18px 36px rgba(45, 212, 168, 0.22);
}

.btn-primary:hover,
.btn-primary:focus-visible {
    box-shadow: 0 20px 42px rgba(45, 212, 168, 0.28);
}

.btn-ghost {
    background: transparent;
}

.btn-danger {
    color: #ffe4e6;
    border-color: rgba(251, 113, 133, 0.28);
    background: rgba(251, 113, 133, 0.08);
}

.btn-small {
    min-height: 40px;
    padding: 9px 12px;
    border-radius: 13px;
    font-size: 0.9rem;
}

.btn-full {
    width: 100%;
}

.muted {
    color: var(--text-muted);
}

.small {
    font-size: 0.88rem;
}

.text-link {
    color: var(--primary);
}

.alert {
    border-radius: 18px;
    padding: 14px 16px;
    border: 1px solid transparent;
    box-shadow: var(--shadow-sm);
}

.alert p {
    margin: 0;
}

.alert-success {
    background: rgba(22, 163, 74, 0.14);
    border-color: rgba(34, 197, 94, 0.2);
    color: #d1fae5;
}

.alert-error {
    background: rgba(251, 113, 133, 0.12);
    border-color: rgba(251, 113, 133, 0.18);
    color: #ffe4e6;
}

.toolbar-grid {
    flex-wrap: wrap;
    align-items: stretch;
    margin-bottom: 18px;
}

.toolbar-grid > * {
    flex: 1 1 180px;
}

.toolbar-grid .btn {
    flex: 0 0 auto;
}

.search-field {
    position: relative;
    flex: 1 1 320px;
}

.search-field svg {
    position: absolute;
    left: 16px;
    top: 50%;
    width: 18px;
    height: 18px;
    transform: translateY(-50%);
    color: var(--text-muted);
}

.search-field input {
    padding-left: 46px;
}

.bookmark-list {
    display: grid;
    gap: 16px;
}

.link-page-list {
    display: grid;
    grid-template-columns: repeat(var(--link-page-columns, 6), minmax(0, 1fr));
    gap: 8px;
}

.link-page-card {
    position: relative;
    min-width: 0;
}

.link-page-item {
    appearance: none;
    display: block;
    width: 100%;
    min-width: 0;
    padding: 10px 12px;
    padding-right: 52px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.03);
    box-shadow: var(--shadow-sm);
    color: var(--text);
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.35;
    text-align: left;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: pointer;
    transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.link-page-item-title {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.link-page-actions {
    position: absolute;
    top: 7px;
    right: 7px;
    display: flex;
    align-items: center;
    visibility: hidden;
    opacity: 0;
    transform: translateY(-4px) scale(0.96);
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease;
}

.link-page-action {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    min-height: 34px;
    padding: 7px 10px;
    border-radius: 10px;
    border: 1px solid rgba(45, 212, 168, 0.18);
    background: rgba(12, 16, 24, 0.9);
    box-shadow: 0 12px 24px rgba(3, 7, 18, 0.24);
    color: var(--text);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.link-page-card.is-action-visible .link-page-actions {
    visibility: visible;
    opacity: 1;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.link-page-card.is-action-visible .link-page-item {
    border-color: rgba(45, 212, 168, 0.24);
    box-shadow: 0 18px 34px rgba(3, 7, 18, 0.22);
}

.link-page-action:hover,
.link-page-action:focus-visible {
    border-color: rgba(45, 212, 168, 0.36);
    color: var(--primary);
}

.link-page-item:focus-visible,
.link-page-action:focus-visible {
    outline: 2px solid rgba(45, 212, 168, 0.46);
    outline-offset: 2px;
}

.link-page-card.is-favorite .link-page-item {
    border-color: rgba(45, 212, 168, 0.24);
    background: linear-gradient(135deg, rgba(45, 212, 168, 0.12), rgba(18, 24, 38, 0.72));
}

.link-page-card.is-favorite.is-action-visible .link-page-item {
    border-color: rgba(45, 212, 168, 0.36);
}

.link-page-item:active {
    transform: translateY(0);
}

.link-page-card.is-action-visible .link-page-item:active {
    transform: translateY(0);
}

.link-page-main {
    min-width: 0;
    display: grid;
    gap: 8px;
}

.link-page-title {
    font-size: 1.02rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.link-page-title:hover {
    color: var(--primary);
}

.link-page-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-end;
}

.bookmark-card {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 18px;
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 20px;
    background:
        linear-gradient(180deg, rgba(31, 37, 51, 0.94), rgba(23, 27, 37, 0.94)),
        radial-gradient(circle at top left, rgba(45, 212, 168, 0.08), transparent 24%);
    box-shadow: var(--shadow-sm);
    transition: transform 0.24s ease, border-color 0.24s ease, box-shadow 0.24s ease;
}

.bookmark-card:hover {
    transform: translateY(-4px);
    border-color: rgba(45, 212, 168, 0.24);
    box-shadow: 0 26px 48px rgba(0, 0, 0, 0.28);
}

.bookmark-main {
    display: grid;
    gap: 14px;
    min-width: 0;
}

.bookmark-meta {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.favicon {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    object-fit: cover;
    border: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(255, 255, 255, 0.06);
    box-shadow: 0 10px 20px rgba(3, 7, 18, 0.22);
}

.favicon.fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    font-weight: 700;
}

.bookmark-title-wrap {
    min-width: 0;
    display: grid;
    gap: 8px;
}

.bookmark-heading-row {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.bookmark-title {
    font-size: 1.08rem;
    font-weight: 700;
    letter-spacing: -0.03em;
}

.bookmark-title:hover {
    color: var(--primary);
}

.bookmark-url {
    color: var(--text-muted);
    word-break: break-all;
    font-size: 0.9rem;
}

.bookmark-description {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.65;
}

.bookmark-actions {
    flex-wrap: wrap;
    align-content: flex-start;
    justify-content: flex-end;
    min-width: 220px;
}

.bookmark-actions form {
    margin: 0;
}

.bookmark-inline-icon {
    width: 16px;
    height: 16px;
    display: inline-flex;
    color: currentColor;
}

.favorite-indicator {
    color: var(--warning);
    font-size: 0.95rem;
}

.tag-row,
.filter-pill-row {
    flex-wrap: wrap;
}

.tag-chip,
.filter-pill,
.state-badge,
.metric-pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    padding: 7px 12px;
    font-size: 0.84rem;
    line-height: 1;
}

.tag-chip {
    background: linear-gradient(135deg, rgba(20, 184, 166, 0.2), rgba(45, 212, 168, 0.12));
    color: #ccfbf1;
    border: 1px solid rgba(45, 212, 168, 0.16);
}

.filter-pill,
.state-badge,
.metric-pill {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--line);
    color: var(--text-soft);
}

.auth-hero .metric-pill {
    justify-content: center;
    font-size: 1rem;
    padding: 10px 14px;
}

.state-badge.favorite {
    color: #ecfccb;
    background: rgba(132, 204, 22, 0.12);
    border-color: rgba(132, 204, 22, 0.18);
}

.pagination {
    flex-wrap: wrap;
    margin-top: 10px;
}

.pagination a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 42px;
    min-height: 42px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--line);
    color: var(--text-soft);
}

.pagination a.active,
.pagination a:hover {
    border-color: rgba(45, 212, 168, 0.2);
    background: rgba(45, 212, 168, 0.16);
    color: var(--text);
}

.detail-grid {
    display: grid;
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.detail-card,
.tag-table-item,
.helper-card,
.hero-card,
.auth-card,
.install-card,
.stat-card,
.bookmarklet-card {
    position: relative;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--line);
    border-radius: 18px;
    padding: 18px;
}

.detail-card h2,
.helper-card h2,
.bookmarklet-card h2,
.stat-card h2 {
    margin-bottom: 12px;
}

.detail-copy {
    margin: 0;
    color: var(--text-soft);
    line-height: 1.7;
}

.meta-list {
    display: grid;
    gap: 12px;
}

.meta-list > div {
    display: grid;
    gap: 6px;
}

.meta-list dt {
    color: var(--text-muted);
    font-size: 0.82rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.meta-list dd {
    margin: 0;
    color: var(--text);
}

.tag-table {
    display: grid;
    gap: 12px;
}

.tag-table-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: nowrap;
}

.tag-table-row {
    flex: 1 1 auto;
    min-width: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.tag-table-item {
    transition: transform 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.tag-table-item:hover {
    transform: translateY(-2px);
    border-color: rgba(45, 212, 168, 0.22);
    background: rgba(45, 212, 168, 0.06);
}

.tag-name {
    font-weight: 600;
}

.tag-count {
    color: var(--primary);
    font-weight: 700;
}

.tag-table-actions {
    margin: 0;
    flex: 0 0 auto;
    display: flex;
    align-items: center;
}

.tag-table-actions .btn {
    width: auto;
    white-space: nowrap;
}

.empty-state {
    text-align: center;
    padding: 30px 24px;
    border-radius: 22px;
    border: 1px dashed rgba(148, 163, 184, 0.22);
    background: rgba(255, 255, 255, 0.03);
    color: var(--text-soft);
}

.empty-state h2 {
    margin-bottom: 12px;
}

.empty-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 14px;
    color: var(--primary);
}

.auth-layout {
    width: min(1120px, 100%);
    display: grid;
    grid-template-columns: 1.15fr 0.9fr;
    gap: 24px;
    align-items: stretch;
}

.auth-hero,
.auth-card,
.install-card,
.helper-card {
    padding: 28px;
}

.auth-hero {
    position: relative;
    overflow: hidden;
    border-radius: 28px;
    background:
        radial-gradient(circle at top left, rgba(45, 212, 168, 0.22), transparent 28%),
        radial-gradient(circle at 85% 15%, rgba(59, 130, 246, 0.22), transparent 24%),
        linear-gradient(160deg, rgba(20, 24, 33, 0.98), rgba(14, 17, 25, 0.92));
    border: 1px solid var(--line);
    box-shadow: var(--shadow-lg);
}

.auth-hero::after {
    content: "";
    position: absolute;
    inset: auto -40px -80px auto;
    width: 220px;
    height: 220px;
    background: radial-gradient(circle, rgba(45, 212, 168, 0.34), transparent 60%);
    filter: blur(16px);
}

.auth-hero h1,
.install-card h1,
.helper-card h1 {
    font-size: clamp(2.2rem, 4vw, 3.2rem);
    letter-spacing: -0.05em;
    margin-bottom: 16px;
}

.auth-copy,
.hero-card p,
.helper-card p {
    color: var(--text-soft);
    line-height: 1.75;
}

.hero-pills,
.stat-grid,
.helper-grid,
.feature-list {
    display: grid;
    gap: 12px;
}

.hero-pills {
    margin-top: 26px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.metric-pill {
    justify-content: center;
}

.auth-card {
    display: grid;
    gap: 18px;
}

.auth-card h2 {
    margin: 0;
    letter-spacing: -0.04em;
}

.auth-card p {
    margin: 0;
}

.helper-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.helper-card h3,
.bookmarklet-card h3,
.stat-card h3 {
    margin-top: 0;
    margin-bottom: 8px;
}

.bookmarklet-output textarea,
.generated-config textarea {
    min-height: 140px;
}

.generated-config {
    margin-top: 18px;
}

.generated-config h2 {
    margin-bottom: 10px;
}

.form-section {
    display: grid;
    gap: 16px;
    padding: 20px;
    border-radius: 18px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.025);
}

.form-section + .form-section {
    margin-top: 4px;
}

.form-section + .form-section.form-section-gap-md {
    margin-top: 18px;
}

.form-section-head {
    display: grid;
    gap: 8px;
}

.form-section-head h2 {
    margin: 0;
}

.inline-group {
    align-items: stretch;
}

.inline-group > *:first-child {
    flex: 1 1 auto;
}

.inline-group > .btn {
    flex: 0 0 auto;
}

.checkbox-row {
    flex-wrap: wrap;
}

.checkbox-row label {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.03);
}

.form-actions,
.button-row {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.form-actions form {
    margin: 0;
}

.stat-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.stat-card .stat-value {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.04em;
}

.stat-card .stat-label {
    color: var(--text-muted);
}

.bookmarklet-card textarea,
.generated-config textarea,
.code-block textarea {
    background: rgba(6, 10, 18, 0.86);
}

.list-steps {
    display: grid;
    gap: 10px;
    margin: 0;
    padding-left: 18px;
    color: var(--text-soft);
}

.error-card {
    max-width: 680px;
    margin: 0 auto;
    text-align: center;
}

.error-card .empty-icon {
    margin-bottom: 18px;
}

.field-note {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.88rem;
}

.bulk-layout {
    align-items: start;
}

.bulk-checkbox {
    height: 100%;
    align-items: end;
}

.bulk-result-list {
    display: grid;
    gap: 10px;
}

.bulk-result-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 14px;
    border-radius: 14px;
    border: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.03);
}

.bulk-result-row.status-created {
    border-color: rgba(45, 212, 168, 0.2);
}

.bulk-result-row.status-duplicate {
    border-color: rgba(250, 204, 21, 0.22);
}

.bulk-result-row.status-failed {
    border-color: rgba(248, 113, 113, 0.22);
}

.bulk-result-main {
    min-width: 0;
    display: grid;
    gap: 4px;
}

.bulk-result-main strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.install-page .standalone-shell,
.install-page .install-shell {
    min-height: 100vh;
    padding: 28px;
}

.install-shell {
    display: flex;
    align-items: center;
    justify-content: center;
}

.install-card {
    width: min(1180px, 100%);
    background:
        radial-gradient(circle at top left, rgba(45, 212, 168, 0.14), transparent 28%),
        linear-gradient(180deg, rgba(23, 27, 37, 0.98), rgba(15, 18, 26, 0.98));
}

.install-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 24px;
    flex-wrap: wrap;
}

.install-grid {
    display: grid;
    grid-template-columns: 1.35fr 0.9fr;
    gap: 20px;
}

.install-aside {
    display: grid;
    gap: 16px;
}

.install-aside .helper-card {
    padding: 20px;
}

.bookmarklet-grid,
.import-grid,
.feature-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
}

.feature-list {
    padding-left: 18px;
    margin: 0;
    color: var(--text-soft);
}

.feature-list li {
    line-height: 1.6;
}

.top-space-sm {
    margin-top: 8px;
}

.top-space-md {
    margin-top: 18px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

@media (max-width: 1180px) {
    .detail-grid,
    .auth-layout,
    .install-grid,
    .bookmarklet-grid,
    .import-grid {
        grid-template-columns: 1fr;
    }

    .helper-grid,
    .hero-pills,
    .stat-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 860px) {
    .drawer-toggle {
        display: inline-flex;
    }

    .drawer-close {
        display: inline-flex;
    }

    .app-sidebar {
        padding: 0;
        width: min(88vw, 320px);
        transform: translateX(-100%);
        transition: transform 0.28s ease;
    }

    body.drawer-open .app-sidebar {
        transform: translateX(0);
    }

    .app-sidebar-inner {
        border-radius: 0 28px 28px 0;
        height: 100vh;
    }

    .content-shell {
        margin-left: 0;
        padding: 86px 16px 28px;
    }
}

@media (max-width: 760px) {
    .two-col {
        grid-template-columns: 1fr;
    }

    .bookmark-card {
        grid-template-columns: 1fr;
    }

    .link-page-list {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 7px;
    }

    .link-page-item {
        padding: 9px 11px;
        padding-right: 50px;
        font-size: 0.9rem;
    }

    .link-page-actions {
        top: 6px;
        right: 6px;
    }

    .link-page-action {
        min-width: 38px;
        min-height: 32px;
        padding: 6px 9px;
    }

    .link-page-meta {
        justify-content: flex-start;
    }

    .bookmark-actions,
    .toolbar-grid,
    .inline-group,
    .button-row,
    .form-actions {
        flex-direction: column;
    }

    .toolbar-grid > *,
    .toolbar-grid .btn,
    .btn,
    .btn-small {
        width: 100%;
    }

    .bookmark-actions {
        min-width: 0;
        justify-content: flex-start;
    }

    .bulk-result-row {
        align-items: flex-start;
        flex-direction: column;
    }

    .panel,
    .panel-soft,
    .auth-card,
    .auth-hero,
    .install-card {
        padding: 20px;
    }

    .page-topbar {
        margin-bottom: 18px;
    }
}

@media print {
    body {
    min-width: 1024px;
        background: #ffffff;
        color: #111827;
    }

    .app-sidebar,
    .drawer-toggle,
    .drawer-overlay,
    .button-row,
    .bookmark-actions,
    .toolbar-grid,
    .logout-form,
    form,
    .btn {
        display: none !important;
    }

    .content-shell {
        margin: 0;
        padding: 0;
    }

    .panel,
    .panel-soft,
    .detail-card,
    .bookmark-card {
        background: #ffffff;
        color: #111827;
        border-color: #d1d5db;
        box-shadow: none;
    }

}

