/* Ski Hub — global styles */
:root {
  --bg: #0A0B0D;
  --bg-2: #111316;
  --panel: #15171A;
  --panel-2: #1E2125;
  --line: #262A2F;
  --line-2: #2A2E33;
  --line-3: #3A3F45;
  --text: #F2F4F5;
  --text-2: #C9CFD4;
  --muted: #9BA3AB;
  --faint: #8A929A;
  --green: #2EF26A;
  --green-hover: #7DFFA6;
  --on-green: #0A0B0D;
  --radius: 14px;
  --font: Manrope, system-ui, -apple-system, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body { background: var(--bg); color: var(--text); font-family: var(--font); font-size: 15px; line-height: 1.5; }
a { color: var(--green); }
a:hover { color: var(--green-hover); }
img { max-width: 100%; display: block; }
input, select, textarea, button { font-family: inherit; font-size: 15px; }
h1, h2, h3 { font-weight: 600; margin: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 0 20px; border-radius: 10px; border: 1px solid transparent; font-weight: 600; text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--green); color: var(--on-green); }
.btn-primary:hover { background: var(--green-hover); color: var(--on-green); }
.btn-dark { background: var(--bg); color: var(--text); }
.btn-dark:hover { color: var(--text); background: #000; }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line-3); }
.btn-ghost:hover { color: var(--text); border-color: var(--muted); }
.btn-light { background: var(--text); color: var(--on-green); }
.btn-light:hover { color: var(--on-green); background: #fff; }
.btn-block { width: 100%; }
.btn-lg { min-height: 52px; font-size: 16px; }

/* Forms */
.field { display: flex; flex-direction: column; gap: 6px; font-size: 13px; font-weight: 600; color: var(--muted); }
.input, .select, .textarea { height: 46px; padding: 0 14px; border-radius: 10px; border: 1px solid var(--line-2); background: var(--bg); color: var(--text); }
.textarea { height: auto; padding: 12px 14px; resize: vertical; }
.input::placeholder, .textarea::placeholder { color: #6E767E; }
.check { display: flex; align-items: center; gap: 8px; font-weight: 500; color: var(--text); font-size: 15px; }
.check input { width: 18px; height: 18px; accent-color: var(--green); }

/* Header / footer */
.site-header { border-bottom: 1px solid #1E2125; }
.site-header .inner { max-width: 1760px; margin: 0 auto; padding: 16px 24px; display: flex; flex-wrap: wrap; align-items: center; gap: 24px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.logo:hover { color: var(--text); }
.logo-mark { width: 36px; height: 36px; border-radius: 8px; background: var(--green); display: flex; align-items: center; justify-content: center; }
.logo-text { font-weight: 600; font-size: 22px; letter-spacing: .5px; }
.logo-text span { color: var(--green); }
.main-nav { display: flex; flex-wrap: wrap; gap: 4px; flex: 1 1 auto; }
.main-nav a { color: #B8C0C7; text-decoration: none; padding: 10px 14px; font-weight: 500; border-radius: 8px; }
.main-nav a:hover, .main-nav a[aria-current="page"] { color: var(--text); background: var(--panel); }
.header-actions { display: flex; gap: 10px; }
.site-footer { border-top: 1px solid #1E2125; background: #08090A; margin-top: 48px; }
.site-footer .inner { max-width: 1760px; margin: 0 auto; padding: 28px 24px; display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; color: var(--faint); font-size: 14px; }
.site-footer nav { display: flex; gap: 20px; flex-wrap: wrap; }
.site-footer nav a { color: #B8C0C7; text-decoration: none; }

/* Page frame with ad rails */
.frame { max-width: 1760px; margin: 0 auto; padding: 0 24px; display: flex; gap: 24px; align-items: flex-start; }
.frame-main { flex: 1 1 0; min-width: 0; padding: 32px 0 0; display: flex; flex-direction: column; gap: 48px; }
.rail { flex: 0 0 160px; position: sticky; top: 24px; padding-top: 32px; display: flex; flex-direction: column; gap: 20px; }
@media (max-width: 1100px) { .rail { display: none; } }

/* Ads */
.ad-label { font-size: 10px; font-weight: 600; letter-spacing: 1.5px; color: var(--faint); text-transform: uppercase; }
.ad-slot { display: flex; flex-direction: column; gap: 6px; }
.ad-sky { width: 160px; height: 600px; border-radius: 12px; overflow: hidden; display: flex; flex-direction: column; }
.ad-sky.empty { border: 1px dashed var(--line-3); background: var(--bg-2); align-items: center; justify-content: center; text-align: center; padding: 12px; gap: 8px; }
.ad-sky.filled { border: 1px solid var(--line-2); background: var(--panel); }
.ad-sky .ad-top { background: var(--green); color: var(--on-green); padding: 16px 14px; display: flex; flex-direction: column; gap: 2px; }
.ad-sky .ad-name { font-size: 20px; font-weight: 600; line-height: 1.1; }
.ad-sky .ad-sub { font-size: 12px; font-weight: 600; letter-spacing: 1.5px; }
.ad-sky .ad-pic { height: 150px; background: var(--panel-2); display: flex; align-items: center; justify-content: center; }
.ad-sky .ad-body { padding: 16px 14px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.ad-sky .ad-tag { margin: 0; font-size: 17px; font-weight: 600; line-height: 1.25; }
.ad-sky ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 13px; color: var(--text-2); }
.ad-sky li::before { content: "✓ "; color: var(--green); }
.ad-sky .ad-place { margin-top: auto; color: var(--muted); font-size: 12px; }
.ad-sky .ad-phone { font-size: 15px; font-weight: 600; color: var(--text); text-decoration: none; }
.ad-sky .btn { min-height: 44px; font-size: 14px; padding: 0 10px; }
.ad-banner { border: 1px dashed var(--line-3); border-radius: var(--radius); background: var(--bg-2); padding: 16px 20px; display: flex; flex-wrap: wrap; align-items: center; gap: 20px; }
.ad-banner .ad-label { flex: 0 0 100%; }
.ad-banner .ad-box { flex: 1 1 320px; min-height: 90px; border-radius: 10px; background: #1A1D21; display: flex; align-items: center; justify-content: center; color: #B8C0C7; font-weight: 600; padding: 12px; text-align: center; }

/* Hero */
.hero { display: flex; flex-wrap: wrap; gap: 24px; }
.hero-search { flex: 999 1 520px; min-width: 0; background: var(--panel); border: 1px solid var(--line); border-radius: 24px; padding: 48px; display: flex; flex-direction: column; gap: 20px; justify-content: center; }
.hero-search h1 { font-size: clamp(32px, 4vw, 48px); line-height: 1.08; }
.hero-search p { margin: 0; color: var(--muted); font-size: 18px; max-width: 520px; }
.search-row { display: flex; flex-wrap: wrap; gap: 10px; }
.search-row .input { flex: 1 1 260px; height: 54px; font-size: 16px; }
.search-row .btn { min-height: 54px; padding: 0 26px; font-size: 16px; }
.hero-sell { flex: 1 1 300px; background: var(--green); color: var(--on-green); border-radius: 24px; padding: 36px; display: flex; flex-direction: column; gap: 14px; justify-content: space-between; }
.hero-sell .eyebrow { margin: 0 0 8px; font-size: 12px; font-weight: 600; letter-spacing: 2px; }
.hero-sell h2 { font-size: 30px; line-height: 1.1; margin-bottom: 10px; }
.hero-sell p { margin: 0; color: #10301B; }
.hero-sell .btn { align-self: flex-start; }
@media (max-width: 600px) { .hero-search, .hero-sell { padding: 28px; } }

/* Sections */
.section-head { display: flex; justify-content: space-between; align-items: end; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.section-head h2 { font-size: 24px; display: flex; align-items: center; gap: 10px; }
.section-head a { font-weight: 600; text-decoration: none; }
.badge { font-size: 10px; font-weight: 600; letter-spacing: 1.5px; background: var(--green); color: var(--on-green); padding: 4px 8px; border-radius: 4px; text-transform: uppercase; }

.tile-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }
.tile { min-height: 110px; border-radius: 16px; background: var(--panel); border: 1px solid var(--line); text-decoration: none; color: var(--text); padding: 20px; display: flex; flex-direction: column; justify-content: space-between; }
.tile:hover { border-color: var(--green); color: var(--text); }
.tile strong { font-size: 20px; font-weight: 600; }
.tile span { color: var(--green); font-size: 14px; font-weight: 500; }
.style-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); }
.style-tile { border-radius: 16px; background: var(--panel); border: 1px solid var(--line); text-decoration: none; color: var(--text); overflow: hidden; display: flex; flex-direction: column; }
.style-tile:hover { border-color: var(--green); color: var(--text); }
.style-tile .pic { height: 110px; background: var(--panel-2); display: flex; align-items: center; justify-content: center; }
.style-tile .txt { padding: 14px 16px; }
.style-tile strong { display: block; font-weight: 600; }
.style-tile small { color: var(--muted); font-size: 13px; }
.state-row { display: flex; flex-wrap: wrap; gap: 10px; }
.state-btn { min-width: 100px; height: 52px; padding: 0 20px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); color: var(--text); text-decoration: none; display: flex; align-items: center; justify-content: center; font-weight: 600; }
.state-btn:hover { border-color: var(--green); color: var(--text); }
.all-states { margin-top: 12px; height: 52px; padding: 0 28px; border-radius: 12px; }

/* Listing cards */
.card-grid { display: grid; gap: 20px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.card { border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); overflow: hidden; text-decoration: none; color: var(--text); display: flex; flex-direction: column; }
.card:hover { color: var(--text); border-color: var(--line-3); }
.card.featured { border: 2px solid var(--green); }
.card .pic { position: relative; height: 170px; background: var(--panel-2); display: flex; align-items: center; justify-content: center; }
.card .pic .badge { position: absolute; top: 10px; left: 10px; }
.card .pic .count { position: absolute; bottom: 10px; right: 10px; background: rgba(10,11,13,.85); font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: 4px; }
.card .body { padding: 14px 16px 16px; display: flex; flex-direction: column; gap: 4px; }
.card .title { font-weight: 600; font-size: 16px; }
.card .price { font-weight: 600; font-size: 20px; color: var(--green); }
.card .meta { color: var(--muted); font-size: 13px; }
.card-ad { grid-column: 1 / -1; }

/* Browse page */
.browse { display: flex; flex-wrap: wrap; gap: 28px; align-items: flex-start; }
.filters { flex: 1 1 240px; max-width: 100%; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.filters h2 { font-size: 16px; }
.results { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.results-head { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }
.results-head h1 { font-size: 28px; }
.results-head .count { color: var(--muted); }
.empty-state { padding: 48px 24px; text-align: center; border: 1px dashed var(--line-3); border-radius: var(--radius); color: var(--muted); }

/* Listing detail */
.crumbs { font-size: 14px; color: var(--muted); }
.crumbs a { color: var(--muted); }
.detail { display: flex; flex-wrap: wrap; gap: 32px; align-items: flex-start; }
.detail-main { flex: 999 1 560px; min-width: 0; display: flex; flex-direction: column; gap: 28px; }
.detail-side { flex: 1 1 320px; max-width: 100%; display: flex; flex-direction: column; gap: 20px; }
.gallery-main { position: relative; height: 460px; border-radius: 16px; background: var(--panel-2); display: flex; align-items: center; justify-content: center; }
.gallery-main .badge { position: absolute; top: 16px; left: 16px; }
.thumbs { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-top: 12px; }
.thumbs button { height: 84px; border-radius: 10px; background: var(--panel-2); border: 1px solid var(--line-2); cursor: pointer; }
.thumbs button[aria-pressed="true"] { border: 2px solid var(--green); }
.title-row { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; align-items: start; }
.title-row h1 { font-size: 36px; line-height: 1.1; margin-bottom: 6px; }
.title-row .sub { margin: 0; color: var(--muted); }
.big-price { font-size: 40px; font-weight: 600; color: var(--green); line-height: 1; text-align: right; }
.big-price small { display: block; color: var(--muted); font-size: 14px; font-weight: 400; margin-top: 6px; }
.spec-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.spec { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; }
.spec span { display: block; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: 1px; font-weight: 600; }
.spec strong { font-size: 18px; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 10px; }
.chip { border: 1px solid var(--line-2); background: var(--panel); border-radius: 999px; padding: 8px 14px; font-size: 14px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: 16px; padding: 24px; display: flex; flex-direction: column; gap: 16px; }
.seller { display: flex; align-items: center; gap: 14px; }
.avatar { width: 56px; height: 56px; border-radius: 50%; background: var(--line-2); display: flex; align-items: center; justify-content: center; font-weight: 600; font-size: 20px; }
.verified { font-size: 12px; font-weight: 600; color: var(--green); border: 1px solid var(--green); border-radius: 999px; padding: 4px 10px; }
.safety { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: flex; gap: 14px; }
.safety h2 { font-size: 16px; margin-bottom: 6px; }
.safety p { margin: 0; color: var(--muted); font-size: 14px; }
.mech { border-radius: 10px; background: #1A1D21; padding: 20px; display: flex; flex-direction: column; gap: 14px; }
.mech ul { margin: 0; padding: 0; list-style: none; display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--text-2); }
.mech li::before { content: "✓ "; color: var(--green); }
.notice { border-radius: 10px; padding: 12px 14px; font-size: 14px; background: rgba(46,242,106,.1); border: 1px solid var(--green); color: var(--text); }

/* Sell page */
.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; }
.steps li { display: flex; align-items: center; gap: 12px; padding: 14px 16px; border-radius: 12px; background: var(--bg-2); border: 1px solid var(--line); color: var(--muted); }
.steps li.done, .steps li.current { background: var(--panel); color: var(--text); }
.steps li.current { border: 2px solid var(--green); }
.steps .n { width: 32px; height: 32px; border-radius: 50%; border: 2px solid var(--line-3); display: flex; align-items: center; justify-content: center; font-weight: 600; flex: 0 0 auto; }
.steps li.done .n { background: var(--green); border-color: var(--green); color: var(--on-green); }
.steps li.current .n { border-color: var(--green); color: var(--green); }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.dropzone { position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 8px; min-height: 170px; border: 2px dashed var(--line-3); border-radius: 12px; background: var(--bg); cursor: pointer; text-align: center; padding: 16px; }
.dropzone input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.thumb-row { display: grid; grid-template-columns: repeat(auto-fill, minmax(100px, 1fr)); gap: 10px; }
.thumb-row img { width: 100%; height: 80px; object-fit: cover; border-radius: 8px; }
.plan { display: flex; gap: 14px; background: var(--panel); border: 1px solid var(--line-3); border-radius: 16px; padding: 20px; cursor: pointer; }
.plan.on { border: 2px solid var(--green); }
.plan input { width: 20px; height: 20px; accent-color: var(--green); margin-top: 2px; }
.plan .row { display: flex; justify-content: space-between; gap: 8px; }
.plan strong { font-size: 17px; font-weight: 600; }
.plan small { display: block; color: var(--muted); font-size: 14px; margin-top: 6px; }
.summary { background: var(--bg-2); border: 1px solid var(--line); border-radius: 16px; padding: 20px; display: flex; flex-direction: column; gap: 10px; }
.summary .line { display: flex; justify-content: space-between; color: var(--muted); }
.summary .total { border-top: 1px solid var(--line); padding-top: 10px; display: flex; justify-content: space-between; font-weight: 600; font-size: 18px; }
.summary .total span:last-child { color: var(--green); }
.notice.error { background: rgba(255,107,107,.1); border-color: #FF6B6B; }
code { background: var(--panel-2); padding: 1px 6px; border-radius: 4px; }
