/* X-WIRELESS Cellphone Repair — site styles
   Change brand colors here: */
:root {
  /* Brand: deep blue + silver (matched to the X-WIRELESS logo) */
  --navy: #0b1f4b;      /* deep brand blue (dark sections) */
  --navy-2: #12306e;
  --red: #1a4fd6;       /* royal blue: primary buttons on light backgrounds */
  --red-dark: #123ba6;
  --blue: #1a4fd6;
  --silver: #b9bfcb;
  --silver-light: #e7eaf0;
  --alert: #d4182b;     /* used only for "Closed" status */
  --green: #12a150;
  --ink: #142033;
  --muted: #5a6577;
  --line: #e3e7ee;
  --bg: #ffffff;
  --bg-soft: #f1f4f9;
  --radius: 14px;
  --shadow: 0 6px 24px rgba(11, 31, 75, .12);
  --max: 1160px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.55;
  font-size: 17px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); text-underline-offset: 3px; }
h1, h2, h3 { line-height: 1.15; margin: 0 0 .5em; letter-spacing: -.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }
.container { max-width: var(--max); margin: 0 auto; padding: 0 20px; }
.section { padding: 64px 0; }
.section.soft { background: var(--bg-soft); }
.section.dark { background: var(--navy); color: #fff; }
.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: .78rem; font-weight: 700; color: var(--blue); margin-bottom: .6em; display: block; }
.lead { font-size: 1.15rem; color: var(--muted); max-width: 680px; }
.dark .lead { color: #c9d3e6; }
.center { text-align: center; }
.center .lead { margin-left: auto; margin-right: auto; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: 10px; top: 10px; background: #fff; padding: 8px 12px; z-index: 999; }

/* Buttons */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  padding: 14px 22px; border-radius: 999px; font-weight: 700; font-size: 1rem;
  text-decoration: none; border: 2px solid transparent; cursor: pointer;
  transition: transform .12s ease, background .12s ease; font-family: inherit; line-height: 1.1;
}
.btn:hover { transform: translateY(-1px); }
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); }
.btn-navy { background: var(--navy); color: #fff; }
.btn-outline { background: #fff; color: var(--navy); border-color: var(--navy); }
.btn-ghost { background: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.35); }
.btn-sm { padding: 10px 16px; font-size: .92rem; }
.btn-block { width: 100%; }

/* Top bar + header */
.topbar { background: var(--navy); color: #c9d3e6; font-size: .86rem; }
.topbar .container { display: flex; gap: 24px; justify-content: flex-end; padding-top: 7px; padding-bottom: 7px; flex-wrap: wrap; }
.topbar a { color: #fff; text-decoration: none; font-weight: 600; }
.site-header { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 1px solid var(--line); }
.site-header > .container { display: flex; align-items: center; justify-content: space-between; height: 70px; gap: 16px; }
.logo { text-decoration: none; color: var(--navy); font-weight: 900; font-size: 1.45rem; letter-spacing: -.02em; display: flex; align-items: center; gap: 8px; }
.logo .x { background: var(--red); color: #fff; border-radius: 8px; width: 34px; height: 34px; display: inline-grid; place-items: center; font-size: 1.2rem; }
.logo small { display: block; font-size: .62rem; font-weight: 700; letter-spacing: .14em; color: var(--muted); text-transform: uppercase; margin-top: -2px; }
.nav { display: flex; align-items: center; gap: 4px; }
.nav a { color: var(--ink); text-decoration: none; font-weight: 600; padding: 8px 12px; border-radius: 8px; font-size: .96rem; }
.nav a:hover, .nav a[aria-current="page"] { background: var(--bg-soft); color: var(--blue); }
.nav .btn { margin-left: 8px; color: #fff; }
.nav .btn:hover { background: var(--red-dark); color: #fff; }
.menu-toggle { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.menu-toggle svg { width: 28px; height: 28px; }

@media (max-width: 960px) {
  .topbar { display: none; }
  .menu-toggle { display: block; }
  .nav { position: absolute; top: 70px; left: 0; right: 0; background: #fff; flex-direction: column; align-items: stretch; padding: 12px 20px 20px; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); display: none; }
  .nav.open { display: flex; }
  .nav a { padding: 12px; }
  .nav .btn { margin: 8px 0 0; }
}

/* Hero */
.hero { background: radial-gradient(1100px 520px at 85% -10%, rgba(64,120,255,.55) 0%, transparent 60%), linear-gradient(160deg, #071737 0%, #0d2a66 100%); color: #fff; padding: 56px 0 64px; }
.hero h1 span { background: linear-gradient(90deg, #f2f2f5, #9d9da6 60%, #e6e6ea); -webkit-background-clip: text; background-clip: text; color: transparent; }
.dark .eyebrow, .hero .eyebrow, .page-hero .eyebrow { color: var(--silver); }
.hero .btn-red, .page-hero .btn-red, .dark .btn-red { background: linear-gradient(180deg, #ffffff, #dfe3ea); color: var(--navy); box-shadow: 0 4px 14px rgba(0,0,0,.25); }
.hero .btn-red:hover, .page-hero .btn-red:hover, .dark .btn-red:hover { background: var(--silver-light); }
.hero .lead { color: #c9d3e6; }
.hero-badges { display: flex; flex-wrap: wrap; gap: 10px 18px; margin: 18px 0 28px; padding: 0; list-style: none; font-weight: 600; font-size: .95rem; }
.hero-badges li { display: flex; align-items: center; gap: 7px; }
.hero-badges svg { width: 18px; height: 18px; color: var(--silver); }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; }

/* Store cards */
.stores { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; margin-top: 36px; }
.store-card { background: #fff; color: var(--ink); border-radius: var(--radius); padding: 22px; box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 6px; }
.store-card h3 { margin: 0; font-size: 1.3rem; }
.store-card .addr { color: var(--muted); margin: 0; }
.store-card .hours-line { font-size: .92rem; color: var(--muted); margin: 0; }
.store-card .actions { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 12px; }
.store-card .more { font-size: .9rem; font-weight: 600; margin-top: 8px; }
.status { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: .9rem; }
.status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: #9aa3b2; }
.status.open { color: var(--green); }
.status.open::before { background: var(--green); box-shadow: 0 0 0 4px rgba(18,161,80,.15); }
.status.closed { color: var(--alert); }
.status.closed::before { background: var(--alert); }
@media (max-width: 720px) { .stores { grid-template-columns: 1fr; } }

/* Pathway tiles */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-top: 28px; }
.tile { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px 20px; text-decoration: none; color: var(--ink); transition: box-shadow .15s, transform .15s, border-color .15s; }
.tile:hover { box-shadow: var(--shadow); transform: translateY(-2px); border-color: transparent; }
.tile .ico { width: 50px; height: 50px; border-radius: 12px; background: linear-gradient(145deg, #f3f5f9, #d3d9e3); color: var(--blue); display: grid; place-items: center; margin-bottom: 14px; }
.tile .ico svg { width: 26px; height: 26px; }
.tile h3 { margin-bottom: .3em; }
.tile p { color: var(--muted); font-size: .95rem; margin: 0 0 .8em; }
.tile .go { color: var(--blue); font-weight: 700; font-size: .95rem; }
@media (max-width: 960px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .tiles { grid-template-columns: 1fr; } }

/* Generic grid + cards */
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.grid-2 { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; align-items: start; }
@media (max-width: 900px) { .grid-3 { grid-template-columns: repeat(2, 1fr); } .grid-2 { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .grid-3 { grid-template-columns: 1fr; } }
.card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.card h3 { display: flex; align-items: center; gap: 10px; }
.card h3 svg { width: 22px; height: 22px; color: var(--blue); flex: none; }
.card p { color: var(--muted); margin: 0 0 .8em; font-size: .97rem; }
.card ul { margin: 0; padding-left: 1.1em; color: var(--muted); font-size: .95rem; }
.card .btn { margin-top: 6px; }

/* Trust bar */
.trust { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; }
.trust div { display: flex; gap: 12px; align-items: flex-start; }
.trust svg { width: 28px; height: 28px; color: var(--blue); flex: none; }
.trust strong { display: block; }
.trust span { color: var(--muted); font-size: .92rem; }
@media (max-width: 900px) { .trust { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .trust { grid-template-columns: 1fr; } }

/* Steps */
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; counter-reset: step; }
.steps .card { position: relative; padding-top: 30px; }
.steps .card::before { counter-increment: step; content: counter(step); position: absolute; top: -16px; left: 22px; width: 36px; height: 36px; border-radius: 50%; background: var(--red); color: #fff; font-weight: 800; display: grid; place-items: center; }
@media (max-width: 800px) { .steps { grid-template-columns: 1fr; gap: 28px; } }

/* Device chips */
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; margin: 16px 0 0; }
.chips li { background: #fff; border: 1px solid var(--line); border-radius: 999px; padding: 7px 14px; font-weight: 600; font-size: .92rem; }
.dark .chips li { background: rgba(255,255,255,.08); border-color: rgba(255,255,255,.18); color: #fff; }

/* Review / profile links */
.profiles { display: flex; flex-wrap: wrap; gap: 12px; justify-content: center; margin-top: 22px; }

/* Location detail */
.loc-block { display: grid; grid-template-columns: 1fr 1.2fr; gap: 0; background: #fff; border-radius: var(--radius); overflow: hidden; box-shadow: var(--shadow); }
.loc-block + .loc-block { margin-top: 26px; }
.loc-info { padding: 28px; }
.loc-info .actions { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0; }
.map { min-height: 340px; border: 0; width: 100%; height: 100%; display: block; }
@media (max-width: 820px) { .loc-block { grid-template-columns: 1fr; } .map { min-height: 280px; } }
.hours { width: 100%; border-collapse: collapse; font-size: .96rem; margin-top: 8px; }
.hours td { padding: 7px 0; border-bottom: 1px solid var(--line); }
.hours td:last-child { text-align: right; font-weight: 600; }
.hours tr.today td { color: var(--blue); background: var(--bg-soft); font-weight: 700; }
.nap { font-style: normal; color: var(--muted); }
.nap strong { color: var(--ink); }

/* Page header */
.page-hero { background: radial-gradient(900px 400px at 90% -20%, rgba(64,120,255,.45) 0%, transparent 60%), linear-gradient(160deg, #071737, #0d2a66); color: #fff; padding: 48px 0; }
.page-hero .lead { color: #c9d3e6; }
.crumbs { font-size: .86rem; color: var(--silver); margin-bottom: 10px; }
.crumbs a { color: #c9d3e6; }

/* FAQ */
.faq { max-width: 820px; margin: 24px auto 0; }
.faq details { border: 1px solid var(--line); border-radius: 12px; padding: 0 20px; margin-bottom: 12px; background: #fff; }
.faq summary { cursor: pointer; font-weight: 700; padding: 18px 0; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--blue); font-size: 1.4rem; line-height: 1; }
.faq details[open] summary::after { content: "–"; }
.faq details p { color: var(--muted); margin: 0 0 18px; }

/* Forms */
.form-card { background: #fff; color: var(--ink); border-radius: var(--radius); box-shadow: var(--shadow); padding: 28px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 560px) { .form-row { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.field label { font-weight: 600; font-size: .92rem; }
.field input, .field select, .field textarea {
  font: inherit; font-size: 16px; padding: 12px 14px; border-radius: 10px; border: 1.5px solid #cfd6e2; background: #fff; color: var(--ink); width: 100%;
}
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(26,79,214,.15); }
.radio-row { display: flex; gap: 18px; flex-wrap: wrap; }
.radio-row label { font-weight: 500; display: flex; gap: 6px; align-items: center; }
.form-note { font-size: .85rem; color: var(--muted); margin-top: 10px; }
.hidden { display: none !important; }

/* CTA band */
.cta-band { background: radial-gradient(800px 300px at 90% 0%, rgba(120,160,255,.45) 0%, transparent 70%), linear-gradient(110deg, #123ba6, #0b1f4b); color: #fff; padding: 52px 0; }
.cta-band .container { display: flex; justify-content: space-between; align-items: center; gap: 24px; flex-wrap: wrap; }
.cta-band h2 { margin: 0; }
.cta-band p { margin: 6px 0 0; color: #d3dcf0; }
.cta-band .btns { display: flex; gap: 10px; flex-wrap: wrap; }
.cta-band .btn-white { background: linear-gradient(180deg, #ffffff, #dfe3ea); color: var(--navy); }

/* Footer */
.site-footer { background: #061433; color: #aab6cc; padding: 52px 0 110px; font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: 1.2fr 1fr 1fr 1fr; gap: 28px; }
.site-footer h4 { color: #fff; margin: 0 0 12px; font-size: 1rem; }
.site-footer a { color: #dfe6f2; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer ul { list-style: none; padding: 0; margin: 0; }
.site-footer li { margin-bottom: 8px; }
.site-footer .nap { color: #aab6cc; }
.site-footer .nap strong { color: #fff; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 32px; padding-top: 20px; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 10px; font-size: .86rem; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .footer-grid { grid-template-columns: 1fr; } }
@media (min-width: 961px) { .site-footer { padding-bottom: 40px; } }

/* Sticky mobile action bar */
.action-bar { position: fixed; left: 0; right: 0; bottom: 0; z-index: 60; display: grid; grid-template-columns: repeat(3, 1fr); background: #fff; border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(11,31,75,.14); padding-bottom: env(safe-area-inset-bottom); }
.action-bar a, .action-bar button { display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; padding: 10px 4px; font: inherit; font-size: .8rem; font-weight: 700; color: var(--navy); background: none; border: 0; text-decoration: none; cursor: pointer; }
.action-bar svg { width: 22px; height: 22px; }
.action-bar .primary { background: var(--blue); color: #fff; }
@media (min-width: 961px) { .action-bar { display: none; } }

/* Store picker modal */
.picker { position: fixed; inset: 0; z-index: 100; background: rgba(6,20,51,.6); display: none; align-items: flex-end; justify-content: center; }
.picker.open { display: flex; }
.picker-panel { background: #fff; width: 100%; max-width: 520px; border-radius: 20px 20px 0 0; padding: 22px 20px calc(22px + env(safe-area-inset-bottom)); animation: up .18s ease-out; }
@media (min-width: 600px) { .picker { align-items: center; } .picker-panel { border-radius: 20px; } }
@keyframes up { from { transform: translateY(30px); opacity: 0; } to { transform: none; opacity: 1; } }
.picker-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.picker-head h3 { margin: 0; }
.picker-close { background: var(--bg-soft); border: 0; width: 36px; height: 36px; border-radius: 50%; font-size: 1.3rem; cursor: pointer; }
.picker-option { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 16px; border: 1.5px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); margin-bottom: 10px; }
.picker-option:hover { border-color: var(--blue); }
.picker-option strong { display: block; font-size: 1.05rem; }
.picker-option span { color: var(--muted); font-size: .9rem; }
.picker-option .arrow { color: var(--blue); font-weight: 800; font-size: 1.3rem; }

/* Utilities */
.mt-0 { margin-top: 0; } .mt-2 { margin-top: 20px; } .mt-3 { margin-top: 32px; }
.text-muted { color: var(--muted); }
.check-list { list-style: none; padding: 0; margin: 0 0 1em; }
.check-list li { padding-left: 30px; position: relative; margin-bottom: 10px; }
.check-list li::before { content: ""; position: absolute; left: 0; top: 4px; width: 20px; height: 20px; border-radius: 50%; background: #e3f6eb url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2312a150' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='20 6 9 17 4 12'/%3E%3C/svg%3E") center/12px no-repeat; }
.dark .check-list li::before { background-color: rgba(61,220,132,.15); }

/* Logo image */
.logo img { height: 46px; width: auto; }
.site-footer .logo img { height: 50px; }
@media (max-width: 520px) { .logo img { height: 38px; } }
.tagline { font-size: .78rem; letter-spacing: .28em; text-transform: uppercase; color: var(--silver); font-weight: 600; }
.since { display: inline-flex; align-items: center; gap: 8px; border: 1px solid rgba(255,255,255,.22); border-radius: 999px; padding: 6px 14px; font-size: .82rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #e4e4e8; margin-bottom: 18px; }

/* Silver accent line under dark hero sections */
.hero, .page-hero { border-bottom: 3px solid; border-image: linear-gradient(90deg, #8e96a6, #eef1f6, #8e96a6) 1; }
.section.dark { background: linear-gradient(160deg, #0b1f4b, #12306e); }

/* =========================================================
   STORE LAYOUT (header, mega menu, product grid, cart)
   ========================================================= */
.shop-header { position: sticky; top: 0; z-index: 50; background: #fff; border-bottom: 0; box-shadow: 0 2px 10px rgba(11,31,75,.06); }
.shop-header .container.head-row { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 28px; height: 78px; }
.shop-header .menu-toggle { display: none; }
.head-search { display: flex; max-width: 620px; width: 100%; justify-self: center; border: 1.5px solid #cfd6e2; border-radius: 999px; overflow: hidden; background: #fff; }
.head-search:focus-within { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(26,79,214,.15); }
.head-search input { flex: 1; border: 0; padding: 11px 18px; font: inherit; font-size: 15px; outline: none; min-width: 0; background: transparent; }
.head-search button { border: 0; background: var(--blue); color: #fff; padding: 0 18px; cursor: pointer; display: grid; place-items: center; }
.head-search button svg { width: 18px; height: 18px; }
.head-actions { display: flex; align-items: center; gap: 6px; }
.head-link { display: flex; align-items: center; gap: 7px; padding: 9px 12px; border-radius: 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: .93rem; }
.head-link:hover { background: var(--bg-soft); }
.head-link svg { width: 22px; height: 22px; }
.cart-link { position: relative; border: 1.5px solid var(--line); }
.cart-count { position: absolute; top: -7px; left: 22px; min-width: 19px; height: 19px; border-radius: 999px; background: #9aa3b2; color: #fff; font-size: .72rem; font-weight: 800; display: grid; place-items: center; padding: 0 5px; }
.cart-count.has { background: var(--blue); }
.cart-total { font-weight: 800; color: var(--navy); }

.shop-nav { position: relative; top: auto; left: auto; right: auto; display: block !important; background: var(--navy); border-top: 0; padding: 0 !important; box-shadow: none !important; }
.shop-nav .nav-row { display: flex; align-items: center; gap: 2px; height: 50px; }
.shop-nav .nav-row > a, .nav-apple { color: #e7eaf0; text-decoration: none; font-weight: 600; font-size: .93rem; padding: 8px 14px; border-radius: 8px; background: none; border: 0; cursor: pointer; font-family: inherit; display: inline-flex; align-items: center; gap: 6px; }
.shop-nav .nav-row > a:hover, .shop-nav .nav-row > a[aria-current="page"], .nav-apple:hover, .nav-apple[aria-expanded="true"], .nav-apple[aria-current="page"] { background: rgba(255,255,255,.1); color: #fff; }
.nav-apple { font-weight: 800; letter-spacing: .02em; }
.nav-apple svg { width: 16px; height: 16px; transition: transform .15s; }
.nav-apple[aria-expanded="true"] svg { transform: rotate(180deg); }
.shop-nav .nav-row .btn { margin-left: auto; background: linear-gradient(180deg, #fff, #dfe3ea); color: var(--navy); }
.shop-nav .nav-row .btn:hover { background: var(--silver-light); color: var(--navy); }

.mega { display: none; position: absolute; left: 0; right: 0; top: 100%; background: #fff; border-top: 3px solid var(--blue); box-shadow: 0 18px 40px rgba(11,31,75,.18); z-index: 60; }
.mega.open, .nav-row:has(.nav-apple:hover) + .mega, .mega:hover { display: block; }
.mega-inner { display: grid; grid-template-columns: 230px 1fr; gap: 28px; padding-top: 24px; padding-bottom: 26px; }
.mega-side { border-right: 1px solid var(--line); padding-right: 22px; display: flex; flex-direction: column; gap: 10px; align-items: flex-start; }
.mega-brand { font-size: .75rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.mega-cat { display: flex; justify-content: space-between; width: 100%; padding: 10px 12px; border-radius: 10px; font-weight: 800; text-decoration: none; color: var(--ink); }
.mega-cat.is-active { background: var(--bg-soft); color: var(--blue); }
.mega-note { font-size: .86rem; color: var(--muted); margin: 0; }
.mega-cols { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px 24px; }
.mega-col h5 { margin: 0 0 6px; font-size: .78rem; text-transform: uppercase; letter-spacing: .1em; color: var(--blue); }
.mega-col ul { list-style: none; margin: 0; padding: 0; }
.mega-col a { display: block; padding: 4px 0; color: var(--ink); text-decoration: none; font-size: .93rem; }
.mega-col a:hover { color: var(--blue); text-decoration: underline; }

@media (max-width: 960px) {
  .shop-header .container.head-row { grid-template-columns: auto 1fr auto; grid-template-areas: "menu logo actions" "search search search"; height: auto; gap: 10px 12px; padding-top: 10px; padding-bottom: 12px; }
  .shop-header .menu-toggle { display: block; grid-area: menu; padding: 4px; }
  .shop-header .logo { grid-area: logo; justify-self: start; }
  .head-search { grid-area: search; max-width: none; }
  .head-actions { grid-area: actions; }
  .head-link:not(.cart-link) { display: none; }
  .cart-total { display: none; }
  .shop-nav { position: static; display: none !important; background: #fff; border-top: 1px solid var(--line); max-height: calc(100vh - 140px); overflow: auto; }
  .shop-nav.open { display: block !important; }
  .shop-nav .nav-row { flex-direction: column; align-items: stretch; height: auto; padding: 10px 20px 18px; }
  .shop-nav .nav-row > a, .nav-apple { color: var(--ink); padding: 12px; justify-content: space-between; }
  .shop-nav .nav-row > a:hover, .nav-apple:hover, .nav-apple[aria-expanded="true"], .nav-apple[aria-current="page"] { background: var(--bg-soft); color: var(--blue); }
  .shop-nav .nav-row .btn { margin: 8px 0 0; background: var(--blue); color: #fff; }
  .mega { position: static; box-shadow: none; border-top: 0; }
  .nav-row:has(.nav-apple:hover) + .mega:not(.open) { display: none; }
  .mega.open { display: block; }
  .mega-inner { grid-template-columns: 1fr; padding-top: 0; gap: 14px; }
  .mega-side { border-right: 0; padding-right: 0; }
  .mega-cols { grid-template-columns: repeat(2, 1fr); }
}

/* Shop page header */
.shop-head { background: var(--bg-soft); border-bottom: 1px solid var(--line); padding: 22px 0 24px; }
.shop-head h1 { font-size: clamp(1.7rem, 3.6vw, 2.4rem); margin: 6px 0 6px; color: var(--navy); }
.shop-head .lead { font-size: 1.02rem; margin: 0; }
.shop-crumbs { font-size: .85rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.shop-crumbs a { color: var(--muted); text-decoration: none; }
.shop-crumbs a:hover { color: var(--blue); }
.shop-crumbs span { color: var(--ink); font-weight: 700; }
.shop-section { padding-top: 28px; }
.shop-layout { display: grid; grid-template-columns: 230px 1fr; gap: 30px; align-items: start; }
.shop-side { position: sticky; top: 150px; border: 1px solid var(--line); border-radius: var(--radius); padding: 18px; max-height: calc(100vh - 170px); overflow: auto; }
.shop-side h4 { margin: 0 0 8px; font-size: .78rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted); }
.shop-side ul { list-style: none; padding: 0; margin: 0 0 18px; }
.shop-side li a, .shop-side li span { display: block; padding: 5px 8px; border-radius: 8px; color: var(--ink); text-decoration: none; font-size: .92rem; }
.shop-side li a:hover { background: var(--bg-soft); color: var(--blue); }
.shop-side .is-active { background: var(--bg-soft); color: var(--blue); font-weight: 700; }
@media (max-width: 900px) { .shop-layout { grid-template-columns: 1fr; } .shop-side { display: none; } }

.chip-row { display: flex; gap: 8px; flex-wrap: wrap; margin: 6px 0 16px; }
.chip { border: 1.5px solid var(--line); background: #fff; border-radius: 999px; padding: 7px 14px; font: inherit; font-size: .88rem; font-weight: 600; color: var(--ink); cursor: pointer; text-decoration: none; }
.chip:hover { border-color: var(--blue); color: var(--blue); }
.chip.is-on { background: var(--navy); border-color: var(--navy); color: #fff; }

.shop-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 18px; }
.shop-search { flex: 1 1 240px; }
.shop-search input, .shop-sort select { width: 100%; font: inherit; font-size: 15px; padding: 10px 16px; border: 1.5px solid #cfd6e2; border-radius: 999px; background: #fff; }
.shop-sort { display: flex; align-items: center; gap: 8px; font-weight: 600; font-size: .9rem; }
.shop-sort select { width: auto; padding: 9px 14px; }
.shop-count { color: var(--muted); font-size: .92rem; }

/* Product cards */
.p-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(215px, 1fr)); gap: 16px; }
.p-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); display: flex; flex-direction: column; overflow: hidden; transition: box-shadow .15s, transform .15s; }
.p-card:hover { box-shadow: var(--shadow); transform: translateY(-2px); }
.p-img { position: relative; display: block; background: radial-gradient(circle at 50% 40%, #fff 0%, #eef1f6 70%); padding: 14px; }
.p-img svg { width: 100%; height: auto; display: block; max-height: 190px; }
.p-badge { position: absolute; top: 10px; left: 10px; background: var(--navy); color: #fff; font-size: .68rem; font-weight: 800; letter-spacing: .12em; padding: 4px 8px; border-radius: 6px; }
.p-body { padding: 14px 14px 16px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.p-name { color: var(--ink); text-decoration: none; font-weight: 700; font-size: .93rem; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; min-height: 3.8em; }
.p-name:hover { color: var(--blue); }
.p-stock { color: var(--green); font-weight: 700; font-size: .82rem; display: flex; align-items: center; gap: 6px; }
.p-stock::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--green); }
.p-price { font-size: 1.45rem; font-weight: 800; color: var(--navy); }
.p-buy { display: flex; gap: 8px; margin-top: auto; }
.p-buy .add-btn { flex: 1; }
.qty { display: inline-flex; align-items: center; border: 1.5px solid #cfd6e2; border-radius: 999px; overflow: hidden; height: 40px; flex: none; }
.qty-btn { width: 32px; height: 100%; border: 0; background: var(--bg-soft); font-size: 1.1rem; font-weight: 700; cursor: pointer; color: var(--navy); }
.qty-btn:hover { background: var(--silver-light); }
.qty-in { width: 38px; height: 100%; border: 0; text-align: center; font: inherit; font-weight: 700; font-size: 15px; -moz-appearance: textfield; }
.qty-in::-webkit-outer-spin-button, .qty-in::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.empty { padding: 30px; text-align: center; color: var(--muted); }
.parts-note { display: flex; gap: 10px; align-items: flex-start; margin-top: 24px; padding: 14px 16px; background: var(--bg-soft); border-radius: 12px; font-size: .9rem; color: var(--muted); }
.parts-note svg { width: 20px; height: 20px; color: var(--blue); flex: none; margin-top: 2px; }
.card.coming h3 svg { color: var(--blue); }

/* Model tiles */
.m-group { margin-top: 26px; }
.m-group h3 { font-size: 1rem; text-transform: uppercase; letter-spacing: .08em; color: var(--blue); margin-bottom: 10px; }
.m-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; }
.m-tile { display: flex; flex-direction: column; gap: 2px; padding: 14px 16px; background: #fff; border: 1px solid var(--line); border-radius: 12px; text-decoration: none; color: var(--ink); transition: border-color .15s, box-shadow .15s; }
.m-tile:hover { border-color: var(--blue); box-shadow: var(--shadow); }
.m-name { font-weight: 700; }
.m-sub { font-size: .82rem; color: var(--muted); }

/* Home shop section */
.sec-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px; flex-wrap: wrap; margin-bottom: 18px; }
.sec-head h2 { margin-bottom: .3em; }
.sec-head .lead { margin: 0; }
.model-strip { display: flex; gap: 8px; overflow-x: auto; padding: 4px 0 14px; margin-bottom: 8px; scrollbar-width: thin; }
.model-strip a { flex: none; padding: 8px 14px; border: 1.5px solid var(--line); border-radius: 999px; text-decoration: none; color: var(--ink); font-weight: 600; font-size: .88rem; white-space: nowrap; }
.model-strip a:hover { border-color: var(--blue); color: var(--blue); }

/* Toast */
.toast { position: fixed; left: 50%; bottom: 84px; transform: translate(-50%, 20px); background: var(--navy); color: #fff; padding: 12px 18px; border-radius: 12px; box-shadow: 0 10px 30px rgba(0,0,0,.25); font-size: .92rem; opacity: 0; pointer-events: none; transition: .2s; z-index: 120; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
.toast a { color: #9cc0ff; font-weight: 700; margin-left: 6px; }
@media (min-width: 961px) { .toast { bottom: 28px; } }

/* Cart */
.cart-layout { display: grid; grid-template-columns: 1fr 380px; gap: 28px; align-items: start; }
@media (max-width: 900px) { .cart-layout { grid-template-columns: 1fr; } }
.cart-row { display: grid; grid-template-columns: 1fr auto 90px 36px; gap: 14px; align-items: center; padding: 16px 0; border-bottom: 1px solid var(--line); }
.cart-name { font-weight: 700; }
.cart-name span { display: block; font-weight: 500; color: var(--muted); font-size: .88rem; }
.cart-line { font-weight: 800; text-align: right; color: var(--navy); }
.cart-remove { border: 0; background: var(--bg-soft); width: 32px; height: 32px; border-radius: 50%; font-size: 1.2rem; cursor: pointer; }
@media (max-width: 560px) { .cart-row { grid-template-columns: 1fr auto; } .cart-line { text-align: left; } }
.cart-empty { padding: 30px 0; }
.cart-summary h3 { margin-bottom: 12px; }
.sum-row { display: flex; justify-content: space-between; padding: 8px 0; border-bottom: 1px solid var(--line); }
.sum-row.total { font-size: 1.15rem; }
.sum-row.total b { color: var(--navy); }
.action-bar { grid-template-columns: repeat(4, 1fr); }
.bar-count { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 999px; background: #fff; color: var(--blue); font-size: .72rem; line-height: 18px; }
.check-field { display: flex; gap: 10px; align-items: center; font-weight: 600; font-size: .92rem; margin: 4px 0 16px; cursor: pointer; }
.check-field input { width: 18px; height: 18px; accent-color: var(--blue); }
/* Product photos (branded cards) */
.p-img { background: #f3f5f9; padding: 12px; display: flex; justify-content: center; }
.p-img img { width: auto; max-width: 100%; height: 300px; object-fit: contain; border-radius: 10px; filter: drop-shadow(0 6px 14px rgba(11,31,75,.15)); transition: transform .2s; }
.p-card:hover .p-img img { transform: scale(1.03); }
@media (max-width: 560px) { .p-img img { height: 380px; } }
/* Checkout / payments */
.pay-box { margin-top: 6px; padding-top: 14px; border-top: 1px solid var(--line); }
.pay-title { display: flex; align-items: center; gap: 8px; font-weight: 700; font-size: .92rem; margin-bottom: 10px; color: var(--navy); }
.pay-title svg { width: 18px; height: 18px; color: var(--green); }
.pay-stripe { margin-bottom: 6px; }
.pay-methods { font-size: .8rem; color: var(--muted); text-align: center; margin: 0 0 12px; }
.paypal-wrap { margin-top: 8px; min-height: 46px; }
.pay-error { background: #fdecee; color: #a3121f; border-radius: 10px; padding: 10px 12px; font-size: .9rem; margin: 8px 0; }
.or-line { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: .85rem; margin: 14px 0; }
.or-line::before, .or-line::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.tax-row span, .total span { color: var(--ink); }
.p-stock.out { color: var(--alert); }
.p-stock.out::before { background: var(--alert); }
.add-btn:disabled { background: #c5cad4; cursor: not-allowed; transform: none; }
/* Logged-in bits */
.topbar .who:empty { display: none; }
.topbar .who { color: #fff; font-weight: 700; }
.shop-nav .nav-row > a.nav-logout { display: none; }
@media (max-width: 960px) { .shop-nav .nav-row > a.nav-logout { display: block; } }
@media (max-width: 1100px) { .logout-link span { display: none; } }
/* Dealer ordering */
.dealer-gate { display: none; }
.is-guest .dealer-gate { display: block; }
.is-guest [data-order-form] { display: none; }
.dealer-gate { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow); padding: 26px; }
.dealer-gate h3 { color: var(--navy); }
.dealer-gate .btns { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 14px; }

/* Top-right Log in button */
.head-link.auth-link { background: var(--blue); color: #fff; border-radius: 999px; padding: 9px 16px; }
.head-link.auth-link:hover { background: var(--red-dark); color: #fff; }
.head-link.auth-link.is-in { background: none; color: var(--ink); border: 1.5px solid var(--line); }
.head-link.auth-link.is-in:hover { background: var(--bg-soft); }
@media (max-width: 960px) {
  .head-link.auth-link { display: flex !important; padding: 8px 12px; font-size: .85rem; }
  .shop-nav .nav-row > a.nav-logout { display: none !important; }
}
/* Products added in the admin panel */
.p-img-btn { border: 0; width: 100%; cursor: zoom-in; display: flex; justify-content: center; }
.p-img-btn img, .p-img-btn svg { width: 100%; height: 220px; object-fit: contain; border-radius: 10px; }
.p-name-btn { background: none; border: 0; padding: 0; text-align: left; font: inherit; font-weight: 700; font-size: .93rem; color: var(--ink); cursor: pointer; min-height: 0; }
.p-name-btn:hover { color: var(--blue); }
.p-cat { font-size: .72rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--blue); }
.p-desc { font-size: .86rem; color: var(--muted); margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.pd-modal { position: fixed; inset: 0; z-index: 150; background: rgba(6,20,51,.6); display: grid; place-items: center; padding: 16px; }
.pd-card { position: relative; background: #fff; border-radius: 18px; max-width: 760px; width: 100%; display: grid; grid-template-columns: 1fr 1fr; gap: 24px; padding: 24px; max-height: 90vh; overflow: auto; }
.pd-img img, .pd-img svg { width: 100%; height: auto; max-height: 420px; object-fit: contain; border-radius: 12px; background: var(--bg-soft); }
.pd-info h2 { font-size: 1.4rem; margin: 4px 0 8px; color: var(--navy); }
.pd-desc { color: var(--muted); white-space: pre-line; }
.pd-close { position: absolute; top: 10px; right: 10px; width: 36px; height: 36px; border-radius: 50%; border: 0; background: var(--bg-soft); font-size: 1.3rem; cursor: pointer; }
@media (max-width: 640px) { .pd-card { grid-template-columns: 1fr; } }
.p-img-btn { height: 244px; align-items: center; }
.p-img-btn img, .p-img-btn svg { height: 100%; width: 100%; }
