:root {
    --bg: #f8fafc;
    --surface: #ffffff;
    --surface-soft: #f1f5f9;
    --border: #e2e8f0;
    --border-strong: #cbd5e1;
    --text: #0f172a;
    --text-secondary: #475569;
    --text-muted: #64748b;
    --brand: #047857;
    --brand-hover: #065f46;
    --brand-soft: #ecfdf5;
    --accent: #b45309;
    --accent-soft: #fffbeb;
    --danger: #dc2626;
    --danger-hover: #b91c1c;
    --danger-soft: #fef2f2;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 1px 3px rgba(15, 23, 42, 0.06), 0 1px 2px rgba(15, 23, 42, 0.04);
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--bg);
    color: var(--text);
    line-height: 1.65;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

a {
    color: var(--brand);
    text-decoration: none;
}

a:hover {
    text-decoration: underline;
}

/* Header & Navigation */
.site-header {
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 50;
}

.header-inner {
    max-width: 960px;
    margin: 0 auto;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}

.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    color: var(--text);
    text-decoration: none;
}

.brand-link:hover {
    text-decoration: none;
}

.brand-logo {
    width: 38px;
    height: 38px;
    object-fit: contain;
    border-radius: 8px;
    flex-shrink: 0;
}

.brand-name {
    font-size: 1rem;
    font-weight: 800;
    letter-spacing: 0.03em;
    color: var(--text);
    line-height: 1.2;
}

.brand-sub {
    display: block;
    font-size: 0.72rem;
    font-weight: 500;
    color: var(--text-muted);
    letter-spacing: 0;
}

.top-nav {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
}

.top-nav a {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    transition: background-color 0.15s ease, color 0.15s ease;
    white-space: nowrap;
}

.top-nav a:hover {
    background: var(--surface-soft);
    color: var(--text);
    text-decoration: none;
}

.top-nav a.active {
    background: var(--brand-soft);
    color: var(--brand);
}

/* Main Content */
.main-wrap {
    flex: 1;
    width: 100%;
    max-width: 960px;
    margin: 0 auto;
    padding: 32px 20px 48px;
}

/* Hero (Landing) */
.hero {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 40px 28px;
    text-align: center;
    box-shadow: var(--shadow);
    margin-bottom: 24px;
}

.hero-logo {
    width: 84px;
    height: 84px;
    object-fit: contain;
    margin-bottom: 14px;
}

.hero h1 {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 800;
    color: var(--text);
    letter-spacing: -0.02em;
    margin-bottom: 8px;
}

.hero p {
    color: var(--text-secondary);
    font-size: 0.98rem;
    max-width: 600px;
    margin: 0 auto;
}

.store-badges {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
    margin-top: 18px;
}

.pill {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 0.78rem;
    font-weight: 600;
    padding: 5px 12px;
    border-radius: 999px;
    background: var(--brand-soft);
    color: var(--brand);
    border: 1px solid #a7f3d0;
}

.pill-neutral {
    background: var(--surface-soft);
    color: var(--text-secondary);
    border: 1px solid var(--border);
}

/* Cards Grid */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 16px;
    margin-bottom: 24px;
}

.nav-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 24px;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    gap: 8px;
    color: var(--text);
    transition: border-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.nav-card:hover {
    border-color: var(--brand);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(15, 23, 42, 0.08);
    text-decoration: none;
}

.nav-card-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: var(--brand);
}

.nav-card.danger-card .nav-card-label {
    color: var(--danger);
}

.nav-card h2 {
    font-size: 1.12rem;
    font-weight: 700;
    color: var(--text);
    margin: 0;
    border: none;
    padding: 0;
}

.nav-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin: 0;
    flex: 1;
}

.nav-card-cta {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--brand);
    margin-top: 8px;
}

.nav-card.danger-card .nav-card-cta {
    color: var(--danger);
}

/* Legal Document Paper */
.doc-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 36px 32px;
    box-shadow: var(--shadow);
}

.doc-header {
    border-bottom: 1px solid var(--border);
    padding-bottom: 20px;
    margin-bottom: 28px;
}

.doc-header h1 {
    font-size: clamp(1.4rem, 3.8vw, 1.85rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    color: var(--text);
    margin-bottom: 8px;
}

.doc-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 20px;
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 10px;
}

.doc-card h2 {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--text);
    margin-top: 30px;
    margin-bottom: 12px;
    padding-bottom: 6px;
    border-bottom: 1px solid var(--surface-soft);
}

.doc-card h3 {
    font-size: 0.98rem;
    font-weight: 700;
    color: var(--text);
    margin-top: 18px;
    margin-bottom: 8px;
}

.doc-card p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 14px;
}

.doc-card ul, .doc-card ol {
    margin: 0 0 16px 20px;
    color: var(--text-secondary);
    font-size: 0.94rem;
}

.doc-card li {
    margin-bottom: 8px;
}

.doc-card li strong {
    color: var(--text);
}

/* Callouts */
.callout {
    border-radius: var(--radius-sm);
    padding: 16px 18px;
    margin: 18px 0;
    font-size: 0.92rem;
    border: 1px solid var(--border);
    background: var(--surface-soft);
    color: var(--text);
}

.callout p:last-child, .callout ul:last-child {
    margin-bottom: 0;
}

.callout-info {
    background: var(--brand-soft);
    border-color: #a7f3d0;
}

.callout-warn {
    background: var(--accent-soft);
    border-color: #fde68a;
}

.callout-danger {
    background: var(--danger-soft);
    border-color: #fecaca;
}

/* Responsive Tables */
.table-wrap {
    width: 100%;
    overflow-x: auto;
    margin: 16px 0 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    -webkit-overflow-scrolling: touch;
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
    min-width: 540px;
}

th, td {
    text-align: left;
    padding: 12px 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: top;
}

th {
    background: var(--surface-soft);
    font-weight: 700;
    color: var(--text);
    white-space: nowrap;
}

td {
    color: var(--text-secondary);
}

tr:last-child td {
    border-bottom: none;
}

/* Forms & Buttons */
.form-section {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    box-shadow: var(--shadow);
    margin-bottom: 20px;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
}

.form-group {
    margin-bottom: 16px;
}

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

label {
    display: block;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 6px;
}

.field-hint {
    display: block;
    font-size: 0.78rem;
    color: var(--text-muted);
    margin-top: 4px;
}

input[type="text"],
input[type="email"],
textarea,
select {
    width: 100%;
    padding: 12px 14px;
    font-size: 0.95rem;
    font-family: inherit;
    color: var(--text);
    background: var(--surface);
    border: 1px solid var(--border-strong);
    border-radius: var(--radius-sm);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
    min-height: 44px;
}

input:focus, textarea:focus, select:focus {
    outline: none;
    border-color: var(--brand);
    box-shadow: 0 0 0 3px rgba(4, 120, 87, 0.15);
}

.checkbox-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 14px;
    background: var(--surface-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
}

.checkbox-row input[type="checkbox"] {
    width: 20px;
    height: 20px;
    margin-top: 2px;
    flex-shrink: 0;
    accent-color: var(--danger);
    cursor: pointer;
}

.checkbox-row span {
    font-size: 0.88rem;
    font-weight: 500;
    color: var(--text);
    line-height: 1.5;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    min-height: 46px;
    font-size: 0.95rem;
    font-weight: 700;
    font-family: inherit;
    border: none;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background-color 0.15s ease, opacity 0.15s ease;
    text-decoration: none;
}

.btn:hover {
    text-decoration: none;
}

.btn-primary {
    background: var(--brand);
    color: #ffffff;
}

.btn-primary:hover {
    background: var(--brand-hover);
}

.btn-danger {
    background: var(--danger);
    color: #ffffff;
}

.btn-danger:hover {
    background: var(--danger-hover);
}

.btn-secondary {
    background: var(--surface-soft);
    color: var(--text);
    border: 1px solid var(--border-strong);
}

.btn-secondary:hover {
    background: var(--border);
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

/* Tabs (Account Deletion vs Status Check) */
.tab-bar {
    display: flex;
    gap: 8px;
    margin-bottom: 20px;
    border-bottom: 1px solid var(--border);
    padding-bottom: 12px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 9px 16px;
    min-height: 40px;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-secondary);
    font-size: 0.88rem;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all 0.15s ease;
}

.tab-btn.active {
    background: var(--text);
    color: #ffffff;
    border-color: var(--text);
}

/* Alerts */
.alert {
    display: none;
    padding: 16px 18px;
    border-radius: var(--radius-sm);
    margin-top: 16px;
    font-size: 0.92rem;
    line-height: 1.55;
}

.alert.show {
    display: block;
}

.alert-success {
    background: var(--brand-soft);
    border: 1px solid #6ee7b7;
    color: #065f46;
}

.alert-error {
    background: var(--danger-soft);
    border: 1px solid #fca5a5;
    color: #991b1b;
}

.tracking-badge {
    display: inline-block;
    margin: 8px 0;
    padding: 6px 14px;
    background: #ffffff;
    border: 1px dashed var(--brand);
    border-radius: 6px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.06em;
    color: var(--text);
}

/* Info Box / Footer */
.support-strip {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
    box-shadow: var(--shadow);
}

.support-strip h3 {
    font-size: 0.98rem;
    margin-bottom: 4px;
}

.support-strip p {
    font-size: 0.88rem;
    color: var(--text-secondary);
}

.site-footer {
    background: var(--surface);
    border-top: 1px solid var(--border);
    padding: 20px;
    text-align: center;
    font-size: 0.82rem;
    color: var(--text-muted);
}

.footer-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 8px;
}

.footer-links a {
    color: var(--text-secondary);
    font-weight: 600;
}

/* Mobile Responsive */
@media (max-width: 680px) {
    .header-inner {
        padding: 10px 14px;
        gap: 10px;
    }

    .top-nav {
        width: 100%;
        justify-content: space-between;
        border-top: 1px solid var(--surface-soft);
        padding-top: 8px;
    }

    .top-nav a {
        flex: 1 1 auto;
        text-align: center;
        padding: 8px 6px;
        font-size: 0.8rem;
    }

    .main-wrap {
        padding: 18px 12px 36px;
    }

    .hero {
        padding: 26px 18px;
    }

    .doc-card, .form-section {
        padding: 22px 16px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .support-strip {
        padding: 18px 16px;
    }
}
