/* Hoopline — shared styles */
:root {
  --bg: #FAFAF8;
  --bg-app: #F4F4F1;
  --surface: #FFFFFF;
  --line: #ECEBE6;
  --line-strong: #DAD9D3;
  --ink: #111214;
  --ink-2: #3B3E45;
  --muted: #565A63;
  --muted-2: #6A6E77;
  --accent: #2448D8;
  --accent-ink: #1A36A8;
  --accent-soft: #EEF1FD;
  --accent-on-dark: #8FA4FF;
  --ok: #2E7D5B;
  --err-bg: #FDECEA;
  --err-ink: #8A1F11;
  --font: 'Space Grotesk', system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  --radius: 22px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 16px/1.55 var(--font); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: var(--accent); }
a:hover { color: var(--accent-ink); }
button, input, select { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.container { max-width: 1200px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.mono { font-family: var(--mono); font-weight: 500; }
.eyebrow { margin: 0; font: 500 13px var(--mono); color: var(--accent); letter-spacing: .06em; text-transform: uppercase; }
.muted { color: var(--muted); }

/* ---------- header ---------- */
.site-header { position: sticky; top: 0; z-index: 20; background: rgba(250,250,248,.92); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.site-header .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; padding-top: 14px; padding-bottom: 14px; }
.brand { display: flex; align-items: center; gap: 10px; min-height: 44px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 19px; letter-spacing: -.02em; }
.brand:hover { color: var(--ink); }
.nav { display: flex; flex-wrap: wrap; align-items: center; gap: 4px; }
.nav a { padding: 10px 12px; color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: 15px; }
.nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }
.nav a:hover { color: var(--ink); }
.nav a.btn-dark, .nav a.btn-dark:hover { color: #fff; }

/* ---------- buttons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 48px; padding: 0 22px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 16px; cursor: pointer; white-space: nowrap; }
.btn:hover { color: var(--ink); border-color: #C8C7C0; }
.btn-dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-dark:hover { color: #fff; background: #26282D; }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #fff; }
.btn-accent:hover { color: #fff; background: var(--accent-ink); }
.btn-lg { min-height: 54px; padding: 0 26px; font-size: 17px; }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: 15px; }
.btn:disabled { opacity: .55; cursor: progress; }

/* ---------- sections ---------- */
.section { padding-top: 112px; padding-bottom: 72px; }
.section-head { display: flex; flex-direction: column; gap: 12px; max-width: 640px; margin-bottom: 44px; }
.section-head.center { margin-left: auto; margin-right: auto; align-items: center; text-align: center; }
h1, h2, h3 { margin: 0; letter-spacing: -.035em; }
.h2 { font-size: clamp(32px, 4.5vw, 48px); line-height: 1.05; font-weight: 700; }

/* ---------- hero ---------- */
.hero { padding-top: 96px; padding-bottom: 48px; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 24px; }
.pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px; border-radius: 999px; background: var(--accent-soft); color: var(--accent-ink); font-size: 13px; font-weight: 600; }
.hero h1 { max-width: 900px; font-size: clamp(44px, 7vw, 84px); line-height: .98; letter-spacing: -.045em; font-weight: 700; }
.hero p.lead { margin: 0; max-width: 600px; font-size: 19px; color: var(--muted); }
.hero .actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; margin-top: 8px; }
.hero .note { margin: 0; font-size: 14px; color: var(--muted-2); }

.stages { background: var(--surface); border: 1px solid var(--line); border-radius: 28px; padding: 28px; box-shadow: 0 30px 60px -30px rgba(17,18,20,.18); display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 20px; }
.stage { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.stage .frame { border-radius: 18px; overflow: hidden; aspect-ratio: 3 / 4; display: flex; align-items: center; justify-content: center; }
.stage .frame img { width: 100%; height: 100%; object-fit: cover; }
.stage .frame.contain img { object-fit: contain; }
.stage figcaption { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: 15px; font-weight: 600; }
.stage .num { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; font: 500 13px var(--mono); margin-right: 10px; }
.stage .meta { font: 500 12px var(--mono); color: var(--muted); }

/* ---------- format strip ---------- */
.strip { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); background: var(--surface); }
.strip .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 20px; padding-top: 28px; padding-bottom: 28px; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { display: inline-flex; align-items: baseline; gap: 8px; padding: 8px 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg); font-size: 13px; color: var(--muted); }
.chip b { font: 500 13px var(--mono); color: var(--ink); }

/* ---------- steps ---------- */
.steps { margin: 0; padding: 0; list-style: none; display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); border-top: 1px solid var(--line-strong); }
.steps li { padding: 28px 28px 8px 0; display: flex; flex-direction: column; gap: 12px; }
.steps .n { font: 500 14px var(--mono); color: var(--muted-2); }
.steps h3 { font-size: 24px; letter-spacing: -.02em; font-weight: 600; }
.steps p { margin: 0; color: var(--muted); max-width: 340px; }

/* ---------- dark feature ---------- */
.dark-card { background: var(--ink); color: #F4F4F1; border-radius: 32px; padding: clamp(28px, 5vw, 64px); display: flex; flex-wrap: wrap; gap: 48px; align-items: center; }
.dark-card .copy { flex: 1 1 380px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.dark-card .eyebrow { color: var(--accent-on-dark); }
.dark-card h2 { font-size: clamp(30px, 4vw, 44px); line-height: 1.05; font-weight: 700; }
.dark-card p { margin: 0; color: #B4B7BF; font-size: 17px; max-width: 460px; }
.ticks { margin: 8px 0 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 12px; }
.ticks li { display: flex; gap: 12px; align-items: flex-start; }
.ticks svg { flex: none; margin-top: 3px; }
.dark-card .ticks li { color: #E2E3E7; }
.dark-card .demo { flex: 1 1 420px; min-width: 0; background: #FFFFFF; border-radius: 22px; padding: 20px; }

/* ---------- cards ---------- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 16px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; display: flex; flex-direction: column; gap: 10px; }
.card h3 { font-size: 19px; letter-spacing: -.01em; font-weight: 600; }
.card p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- pricing ---------- */
.pricing { border-top: 1px solid var(--line); background: var(--surface); }
.plans { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; }
.plan { background: var(--bg); border: 1px solid var(--line); border-radius: 24px; padding: 26px; display: flex; flex-direction: column; gap: 14px; }
.plan.hl { background: var(--surface); border: 2px solid var(--accent); box-shadow: 0 24px 48px -28px rgba(36,72,216,.45); }
.plan .top { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-height: 28px; }
.plan h3 { font-size: 18px; font-weight: 600; letter-spacing: -.01em; }
.badge { padding: 4px 10px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 12px; font-weight: 600; }
.price { margin: 0; display: flex; align-items: baseline; gap: 6px; }
.price b { font-size: 42px; letter-spacing: -.04em; }
.price span { color: var(--muted-2); font-size: 15px; }
.credits { margin: 0; font: 500 13px var(--mono); color: var(--accent); }
.plan ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 8px; font-size: 15px; color: var(--ink-2); }
.plan li { display: flex; gap: 10px; align-items: flex-start; }
.plan li svg { flex: none; margin-top: 4px; }
.plan .btn { margin-top: auto; }

/* ---------- faq ---------- */
.faq { border-top: 1px solid var(--line-strong); }
.faq details { border-bottom: 1px solid var(--line-strong); }
.faq summary { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; font-size: 17px; font-weight: 600; cursor: pointer; list-style: none; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary svg { flex: none; transition: transform .15s; }
.faq details[open] summary svg { transform: rotate(45deg); }
.faq p { margin: 0 0 22px; color: var(--muted); max-width: 680px; }

/* ---------- cta + footer ---------- */
.cta { border-radius: 32px; background: var(--accent); color: #fff; padding: clamp(32px, 6vw, 72px); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 28px; }
.cta h2 { max-width: 560px; font-size: clamp(30px, 4vw, 46px); line-height: 1.05; font-weight: 700; }
.site-footer { border-top: 1px solid var(--line); }
.site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 20px; padding-top: 40px; padding-bottom: 40px; font-size: 14px; color: var(--muted); }
.site-footer nav { display: flex; flex-wrap: wrap; gap: 4px 20px; }
.site-footer nav a { color: var(--muted); text-decoration: none; padding: 10px 0; }
.site-footer nav a:hover { color: var(--ink); }

/* ---------- parts inspector ---------- */
.parts-box { position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden; }
.parts-box svg { width: 100%; height: 100%; }
.parts-box svg path { transition: opacity .12s; cursor: crosshair; }
.parts-box svg:hover path { opacity: .22; }
.parts-box svg path:hover { opacity: 1; stroke: var(--accent); stroke-width: .45; paint-order: stroke; }
.tip { position: absolute; pointer-events: none; background: var(--ink); color: #fff; font-size: 13px; line-height: 1.45; padding: 9px 11px; border-radius: 10px; white-space: nowrap; z-index: 2; box-shadow: 0 12px 30px rgba(17,18,20,.25); }
.tip b { font-weight: 600; }
.tip .sw { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: -1px; border: 1px solid rgba(255,255,255,.4); }

/* ---------- guides ---------- */
.search { display: flex; align-items: center; gap: 10px; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 999px; padding: 0 8px 0 18px; }
.search input { flex: 1; min-width: 0; min-height: 52px; border: 0; background: transparent; outline: none; font-size: 16px; }
.filter { min-height: 44px; padding: 0 18px; border-radius: 999px; border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink); font-weight: 500; font-size: 15px; cursor: pointer; }
.filter[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.guide-card { display: flex; flex-direction: column; gap: 10px; min-height: 168px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; text-decoration: none; color: var(--ink); }
.guide-card:hover { color: var(--ink); border-color: var(--line-strong); }
.guide-card .cat { font: 500 12px var(--mono); color: var(--accent); letter-spacing: .04em; text-transform: uppercase; }
.guide-card .t { font-size: 20px; line-height: 1.25; letter-spacing: -.02em; font-weight: 600; }
.guide-card .d { color: var(--muted); font-size: 15px; }
.guide-card .time { margin-top: auto; font: 500 12px var(--mono); color: var(--muted-2); }
.guide-card.soon { cursor: default; }
.guide-card.soon .time { color: var(--muted-2); }

.article { font-size: 17px; line-height: 1.65; }
.toc { flex: 1 1 220px; max-width: 260px; display: flex; flex-direction: column; gap: 4px; }
.toc a { display: flex; gap: 10px; padding: 8px 0; color: var(--ink-2); text-decoration: none; font-size: 15px; line-height: 1.4; }
.toc a span { font: 500 13px var(--mono); color: var(--muted-2); }
.step { display: flex; gap: 20px; scroll-margin-top: 90px; }
.step .n { flex: none; display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 50%; background: var(--ink); color: #fff; font: 500 14px var(--mono); }
.step h2 { font-size: 24px; line-height: 1.25; letter-spacing: -.02em; font-weight: 600; }
.step p { margin: 8px 0 0; color: var(--ink-2); }
.callout { display: flex; gap: 14px; padding: 20px; border-radius: 16px; font-size: 16px; }
.callout p { margin: 0; }
.callout.info { background: var(--accent-soft); color: var(--accent-ink); }
.callout.warn { background: #FFF4EA; color: #7A3410; }
.callout svg { flex: none; margin-top: 3px; }

/* What you can make */
.uses { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px 16px; }
@media (max-width: 960px) { .uses { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .uses { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px 12px; } .use-cta { padding: 16px; } .use-cta b { font-size: 17px; } .use-cta .btn { padding: 0 14px; font-size: 14px; } }
.use { margin: 0; display: flex; flex-direction: column; gap: 10px; }
.use img { width: 100%; height: auto; aspect-ratio: 3 / 4; object-fit: cover; border-radius: 18px; border: 1px solid var(--line); background: var(--surface); }
.use figcaption { display: flex; flex-direction: column; gap: 2px; font-size: 15px; }
.use figcaption b { font-weight: 600; }
.use figcaption span { color: var(--muted); font-size: 14px; }
.use-cta { min-height: 100%; justify-content: center; align-items: flex-start; gap: 12px; padding: 24px; border-radius: 18px; background: var(--accent-soft); border: 1px dashed var(--accent); color: var(--ink); text-decoration: none; }
.use-cta b { font-size: 20px; font-weight: 700; }
.use-cta span:not(.btn) { color: var(--muted); font-size: 15px; }
.use-cta:hover { color: var(--ink); background: #E4E9FC; }

/* Language switcher and "also available in" banner */
.lang-switch { position: relative; }
.lang-switch summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; padding: 0 10px; border-radius: 999px; cursor: pointer; color: var(--ink-2); font: 500 14px var(--mono); }
.lang-switch summary::-webkit-details-marker { display: none; }
.lang-switch summary:hover, .lang-switch[open] summary { color: var(--ink); background: var(--bg-app); }
.lang-switch ul { position: absolute; right: 0; top: calc(100% + 6px); z-index: 30; margin: 0; padding: 6px; list-style: none; min-width: 200px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: 0 18px 40px -18px rgba(17,18,20,.25); }
.lang-switch li a { display: block; padding: 10px 12px; border-radius: 10px; color: var(--ink-2); text-decoration: none; font-size: 15px; }
.lang-switch li a:hover { background: var(--bg-app); color: var(--ink); }
.lang-switch li a[aria-current="true"] { color: var(--accent-ink); font-weight: 600; }
.lang-banner { background: var(--accent-soft); border-bottom: 1px solid #DCE2FA; }
.lang-banner .container { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding-top: 10px; padding-bottom: 10px; font-size: 15px; color: var(--accent-ink); }
.lang-banner #langBannerText { flex: 1 1 240px; }
.lang-banner .btn { min-height: 40px; }

/* Accounts */
.account-link { padding: 10px 12px; color: var(--ink-2); text-decoration: none; font-weight: 500; font-size: 15px; }
.account-link:hover, .account-link[aria-current="page"] { color: var(--ink); }
.verify-banner { background: #FFF6E5; border-bottom: 1px solid #F2DDB0; }
.verify-banner .container { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding-top: 10px; padding-bottom: 10px; font-size: 15px; color: #6B4A00; }
.verify-banner span { flex: 1 1 260px; overflow-wrap: anywhere; }
.verify-banner .btn { min-height: 40px; }
.auth-page { display: flex; justify-content: center; padding-top: 72px; padding-bottom: 112px; }
.auth-card { width: 100%; max-width: 420px; display: flex; flex-direction: column; gap: 18px; }
.auth-card h1 { font-size: clamp(30px, 5vw, 40px); line-height: 1.05; letter-spacing: -.03em; font-weight: 700; margin: 0; }
.auth-card p { margin: 0; }
.auth-card form { display: flex; flex-direction: column; gap: 16px; }
.auth-card label { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 14px; }
.auth-card input { min-height: 48px; padding: 0 14px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); font: inherit; font-weight: 400; font-size: 16px; color: var(--ink); }
.auth-card input:focus { outline: 2px solid var(--accent); outline-offset: 1px; border-color: transparent; }
.auth-card .hint { font-weight: 400; font-size: 13px; color: var(--muted-2); }
.auth-card .alert { padding: 10px 12px; border-radius: 10px; background: #FDECEC; color: #9B1C1C; font-size: 14px; }
.auth-card .ok-msg { padding: 12px 14px; border-radius: 12px; background: #E9F7EF; color: #136C3A; font-weight: 600; }
.auth-card .links { font-size: 15px; }
.auth-card .small { font-size: 13px; }
.account-list { margin: 0; display: flex; flex-direction: column; border-top: 1px solid var(--line); }
.account-list div { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.account-list dt { color: var(--muted); font-size: 14px; }
.account-list dd { margin: 0; font-weight: 600; display: flex; align-items: center; gap: 10px; overflow-wrap: anywhere; }
.site-notice { background: var(--ink); color: #fff; }
.site-notice .container { padding-top: 9px; padding-bottom: 9px; font-size: 14px; text-align: center; }

/* Legal pages */
.legal { max-width: 760px; padding-top: 64px; padding-bottom: 112px; display: flex; flex-direction: column; gap: 14px; }
.legal h1 { margin: 0; font-size: clamp(34px, 5vw, 48px); letter-spacing: -.035em; font-weight: 700; }
.legal h2 { margin: 28px 0 8px; font-size: 20px; letter-spacing: -.01em; }
.legal p, .legal li { color: var(--ink-2); font-size: 16px; line-height: 1.65; }
.legal p { margin: 0 0 10px; }
.legal ul { margin: 0 0 10px; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }
.legal-note { padding: 10px 14px; border-radius: 12px; background: var(--accent-soft); color: var(--accent-ink) !important; }
.legal-links { display: flex; gap: 18px; flex-wrap: wrap; margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--line); }

/* 404 page */
.notfound { text-align: center; padding-top: 96px; padding-bottom: 140px; max-width: 640px; }
.notfound .code { margin: 0; font-family: "Geist Mono", ui-monospace, monospace; font-size: clamp(72px, 14vw, 128px); line-height: 1; color: var(--accent); }
.notfound h1 { margin: 16px 0 12px; font-size: clamp(28px, 4vw, 40px); }
.notfound p.muted { margin: 0 auto 32px; font-size: 18px; }
.notfound .actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }

/* Checkout */
.checkout-plan { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 18px 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
.checkout-plan b { font-size: 18px; }
.checkout-plan .price { font-weight: 700; font-size: 18px; }
.checkout-plan .muted { grid-column: 1 / -1; font-size: 14px; }
.checkout .small { font-size: 13px; }
.pack-links { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; margin: 14px 0 0; }

/* Header links group and phone menu */
.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-studio { margin-left: 6px; }
.nav-studio .short { display: none; }
.nav-toggle { display: none; align-items: center; justify-content: center; width: 44px; height: 44px; margin-left: 2px; padding: 0; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); color: var(--ink); cursor: pointer; }
.nav-toggle .i-close, .nav-toggle[aria-expanded="true"] .i-open { display: none; }
.nav-toggle[aria-expanded="true"] .i-close { display: block; }
@media (max-width: 900px) {
  .site-header .container { flex-wrap: nowrap; position: relative; padding-top: 10px; padding-bottom: 10px; }
  .nav { flex-wrap: nowrap; gap: 2px; }
  .nav-toggle { display: inline-flex; }
  .nav-studio { margin-left: 4px; }
  .nav-links { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; align-items: stretch; gap: 0;
    padding: 6px 16px 14px; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: 0 24px 40px -24px rgba(17,18,20,.28); }
  .nav-links.open { display: flex; }
  .nav-links a { padding: 15px 4px; font-size: 17px; border-bottom: 1px solid var(--line); }
  .nav-links a:last-child { border-bottom: 0; }
}
@media (max-width: 420px) {
  .brand { font-size: 17px; gap: 8px; }
  .nav-studio { padding: 0 14px; }
  .nav-studio .long { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
  .nav-studio .short { display: inline; }
  .lang-switch summary { padding: 0 6px; }
}

/* ---------- items: design history tiles and the item card ---------- */
.item-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(168px, 1fr)); gap: 12px; }
.item-tile { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 8px 8px 12px; border: 1px solid var(--line); border-radius: 16px; background: var(--surface); text-align: left; cursor: pointer; min-width: 0; }
.item-tile:hover { border-color: var(--line-strong); box-shadow: 0 10px 24px -16px rgba(17,18,20,.3); }
.item-thumb { display: flex; align-items: center; justify-content: center; aspect-ratio: 1; border-radius: 10px; background: #F7F6F2; overflow: hidden; }
.item-thumb img { width: 100%; height: 100%; object-fit: contain; padding: 8px; }
.item-meta { display: flex; flex-direction: column; gap: 2px; padding: 0 4px; min-width: 0; }
.item-name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.item-sub { font-size: 12px; color: var(--muted); }
.item-code { font: 500 11px var(--mono); color: var(--muted-2); letter-spacing: .02em; }
.item-badge { position: absolute; top: 14px; left: 14px; padding: 2px 8px; border-radius: 999px; background: var(--accent); color: #fff; font-size: 11px; font-weight: 600; }
.item-empty { margin: 0; color: var(--muted-2); font-size: 14px; }

.item-card { width: min(880px, calc(100vw - 32px)); max-height: calc(100dvh - 32px); padding: 0; border: 0; border-radius: 22px; background: var(--surface); color: var(--ink); box-shadow: 0 40px 80px -30px rgba(17,18,20,.45); overflow: hidden; }
.item-card[open] { display: flex; flex-direction: column; }
.item-card::backdrop { background: rgba(17,18,20,.45); }
.ic-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 14px 14px 14px 22px; border-bottom: 1px solid var(--line); }
.ic-head h2 { font-size: 18px; letter-spacing: -.01em; font-weight: 600; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ic-close { flex: none; width: 44px; height: 44px; border-radius: 50%; border: 0; background: var(--bg-app); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.ic-body { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); grid-auto-rows: max-content; align-content: start; gap: 22px; padding: 22px; overflow-y: auto; }
.ic-preview { display: flex; align-items: center; justify-content: center; border-radius: 16px; background: #F7F6F2; background-image: radial-gradient(#E3E1DA 1px, transparent 1px); background-size: 18px 18px; padding: 18px; min-height: 280px; }
.ic-preview img { max-height: 440px; object-fit: contain; }
.ic-info { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ic-label { font-size: 13px; font-weight: 600; color: var(--muted); }
.ic-id { display: flex; flex-direction: column; gap: 6px; }
.ic-id-row { display: flex; align-items: center; gap: 8px; min-width: 0; }
.ic-code { flex: 1; min-width: 0; padding: 11px 12px; border-radius: 12px; background: var(--bg-app); font: 500 15px var(--mono); letter-spacing: .03em; overflow-wrap: anywhere; user-select: all; }
.ic-date { margin: 0; font-size: 14px; color: var(--muted); }
.ic-stats { margin: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.ic-stats div { background: var(--bg); border-radius: 12px; padding: 9px 12px; }
.ic-stats dt { font-size: 12px; color: var(--muted); }
.ic-stats dd { margin: 0; font: 500 16px var(--mono); }
.ic-threads { display: flex; flex-wrap: wrap; gap: 6px; }
.ic-threads:empty { display: none; }
.ic-threads .sw { width: 22px; height: 22px; border-radius: 50%; border: 1px solid rgba(17,18,20,.12); }
.ic-dl { display: flex; flex-direction: column; gap: 8px; }
.ic-formats { display: grid; grid-template-columns: repeat(auto-fill, minmax(64px, 1fr)); gap: 6px; }
.ic-formats:empty { display: none; }
.ic-formats a { display: flex; align-items: center; justify-content: center; min-height: 40px; border-radius: 10px; border: 1px solid var(--line-strong); color: var(--ink); text-decoration: none; font: 500 12px var(--mono); }
.ic-zip { min-height: 44px; font-size: 14px; background: var(--bg); }
.ic-share { display: flex; flex-direction: column; gap: 10px; padding-top: 16px; border-top: 1px solid var(--line); }
.ic-share-open.on { border-color: var(--accent); color: var(--accent-ink); }
.ic-share-panel { display: flex; flex-direction: column; gap: 10px; padding: 14px; border-radius: 14px; background: var(--accent-soft); }
.ic-share-note { margin: 0; font-size: 14px; color: var(--ink-2); }
.ic-share-on { display: flex; flex-direction: column; gap: 6px; }
.ic-url { flex: 1; min-width: 0; min-height: 44px; padding: 0 12px; border: 1px solid var(--line-strong); border-radius: 12px; background: var(--surface); font: 500 13px var(--mono); }
.ic-stop { align-self: flex-start; min-height: 40px; padding: 0 2px; border: 0; background: none; color: var(--err-ink); font-weight: 600; font-size: 14px; cursor: pointer; text-decoration: underline; text-underline-offset: 3px; }
.ic-err { margin: 0; padding: 8px 10px; border-radius: 10px; background: var(--err-bg); color: var(--err-ink); font-size: 14px; }
@media (max-width: 720px) {
  .item-card { width: 100vw; max-width: 100vw; max-height: 100dvh; height: 100dvh; border-radius: 0; margin: 0; }
  .ic-body { grid-template-columns: minmax(0, 1fr); padding: 16px; gap: 16px; }
  .ic-preview { min-height: 220px; }
  .ic-preview img { max-height: 300px; }
  .item-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
}

/* ---------- account: my designs ---------- */
.designs { padding-bottom: 112px; display: flex; flex-direction: column; gap: 18px; }
.designs-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; }
.designs-head h2 { font-size: clamp(24px, 3.5vw, 30px); font-weight: 700; }
.designs .more { align-self: center; }

/* ---------- shared item page ---------- */
.share-page { padding-top: 56px; padding-bottom: 112px; display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); gap: 32px; align-items: start; }
.share-page .ic-preview { min-height: 360px; border: 1px solid var(--line); }
.share-page .ic-preview img { max-height: 560px; }
.share-page h1 { font-size: clamp(30px, 5vw, 42px); line-height: 1.05; font-weight: 700; }
.share-page .ic-code { flex: none; }
@media (max-width: 820px) { .share-page { grid-template-columns: minmax(0, 1fr); padding-top: 28px; gap: 22px; } .share-page .ic-preview { min-height: 260px; } }
