:root {
  --ink: #050505;
  --muted: #66615f;
  --line: #e6e2df;
  --soft: #f7f5f3;
  --cream: #fff4f1;
  --brand: #f12502;
  --brand-deep: #c81e00;
  --green: #f12502;
  --white: #ffffff;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.14);
  --radius: 22px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background: #f7f7f7;
  font-family: "Montserrat", ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}
button, input, select { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { color: inherit; }
a { color: inherit; text-decoration: none; }
.skip-link { position: fixed; left: 16px; top: -80px; z-index: 1000; padding: 10px 16px; background: var(--ink); color: white; border-radius: 8px; }
.skip-link:focus { top: 12px; }

.site-header {
  height: 64px;
  padding: 0 clamp(22px, 5vw, 76px);
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(229, 231, 235, .8);
}
.brand { display: inline-flex; align-items: center; }
.brand img { display: block; width: 174px; height: auto; }
.header-support { border: 0; background: var(--ink); color: white; border-radius: 999px; padding: 10px 15px; cursor: pointer; font-size: 12px; font-weight: 800; }
.header-support:hover { background: var(--brand); }

.button { display: inline-flex; align-items: center; justify-content: center; gap: 20px; padding: 15px 21px; border-radius: 10px; border: 1px solid transparent; font-size: 13px; font-weight: 850; cursor: pointer; transition: transform .2s, box-shadow .2s, background .2s; }
.button:hover { transform: translateY(-1px); }
.button-primary { background: var(--brand); color: white; box-shadow: 0 9px 24px rgba(241, 37, 2, .28); }
.button-primary:hover { background: #ff3c1b; }
.catalogue-section { min-height: calc(100vh - 64px); padding: 30px clamp(22px, 4vw, 64px) 96px; background: #f7f7f7; }
.section-heading { max-width: 1440px; margin: 0 auto 18px; }
.section-heading h1 { margin: 0; font-family: "Montserrat", sans-serif; font-size: clamp(28px, 3vw, 40px); font-weight: 900; letter-spacing: -1.4px; line-height: 1; }
.catalogue-tools { max-width: 1440px; margin: 0 auto 18px; display: flex; gap: 10px; position: sticky; top: 64px; z-index: 15; padding: 10px 0; background: rgba(247,247,247,.96); backdrop-filter: blur(12px); }
.search-box { max-width: 660px; flex: 1; display: flex; gap: 10px; align-items: center; padding: 0 15px; border: 1px solid #d8d8d8; background: white; border-radius: 11px; }
.search-box span { font-size: 24px; transform: rotate(-20deg); color: #777f8b; }
.search-box input { width: 100%; padding: 14px 0; border: 0; outline: 0; background: transparent; font-size: 13px; }
.filter-toggle { display: none; padding: 0 17px; border: 1px solid var(--line); border-radius: 10px; background: white; font-weight: 800; cursor: pointer; }
.filter-toggle span:not(:empty) { margin-left: 5px; display: inline-grid; place-items: center; min-width: 19px; height: 19px; padding: 0 5px; color: white; background: var(--ink); border-radius: 999px; font-size: 10px; }
.catalogue-layout { max-width: 1440px; margin: auto; display: grid; grid-template-columns: 205px 1fr; gap: 30px; }
.filters { border-top: 1px solid var(--line); }
.filter-title { display: flex; justify-content: space-between; align-items: center; padding: 19px 0; border-bottom: 1px solid var(--line); font-size: 13px; }
.filter-title button { padding: 0; border: 0; background: none; color: var(--brand-deep); font-size: 11px; cursor: pointer; }
fieldset { padding: 20px 0; margin: 0; border: 0; border-bottom: 1px solid var(--line); }
legend { width: 100%; margin-bottom: 13px; font-size: 12px; font-weight: 900; }
fieldset label { display: flex; align-items: center; min-height: 29px; gap: 8px; color: #596170; font-size: 11px; cursor: pointer; }
fieldset label span { margin-left: auto; color: #a0a4ac; font-size: 10px; }
input[type="checkbox"], input[type="radio"] { width: 14px; height: 14px; accent-color: var(--brand); }
.muted-choice { opacity: .65; }
.results-meta { min-height: 42px; display: flex; justify-content: space-between; align-items: start; gap: 20px; }
.results-meta p { margin: 4px 0; color: var(--muted); font-size: 12px; }
.results-meta strong { color: var(--ink); }
.results-meta label { color: var(--muted); font-size: 11px; }
.results-meta select { margin-left: 8px; padding: 7px 10px; border: 1px solid var(--line); border-radius: 7px; background: white; color: var(--ink); font-size: 11px; font-weight: 700; }
.device-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 14px; }
.device-card { min-width: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 15px; background: white; transition: transform .2s ease, box-shadow .2s ease; }
.device-card:hover { transform: translateY(-3px); border-color: #ffc4b9; box-shadow: 0 16px 36px rgba(0,0,0,.09); }
.device-image { position: relative; height: 190px; display: grid; place-items: center; overflow: hidden; background: linear-gradient(145deg, #f7f7f7, #eceef1); }
.device-image.teal { background: linear-gradient(145deg, #eff8f6, #dcece7); }
.device-image.gold { background: linear-gradient(145deg, #faf5ea, #eee1c6); }
.device-image.blue { background: linear-gradient(145deg, #eef3fa, #d8e3f2); }
.device-image.purple { background: linear-gradient(145deg, #f4f0f7, #e5d8ea); }
.device-image.slate { background: linear-gradient(145deg, #edf0f2, #d5dade); }
.product-phone { width: 91px; height: 175px; position: relative; border-radius: 17px; background: var(--phone-color, #2c343e); box-shadow: 8px 10px 20px rgba(17,24,39,.22), inset -5px -6px 12px rgba(0,0,0,.15); transform: rotate(-5deg); border: 2px solid rgba(255,255,255,.45); }
.product-photo { position: relative; z-index: 2; width: 88%; height: 88%; object-fit: contain; filter: drop-shadow(0 18px 24px rgba(0,0,0,.2)); }
.product-phone::before, .product-phone::after { content: ""; position: absolute; border-radius: 50%; background: radial-gradient(circle at 45% 42%, #334156 0 16%, #0a0d12 20% 56%, #77818b 59% 68%, #181c22 70%); }
.product-phone::before { width: 25px; height: 25px; left: 9px; top: 11px; box-shadow: 0 31px 0 -1px rgba(25,29,35,1); }
.product-phone::after { width: 8px; height: 8px; left: 39px; top: 15px; }
.product-logo { position: absolute; left: 50%; bottom: 18px; transform: translateX(-50%); color: rgba(255,255,255,.55); font-size: 5px; letter-spacing: 1px; text-transform: uppercase; }
.device-badge { position: absolute; left: 12px; top: 12px; padding: 6px 8px; border-radius: 6px; color: white; background: var(--brand); font-size: 8px; font-weight: 900; letter-spacing: .6px; text-transform: uppercase; }
.device-badge.sample { color: #765114; background: #fff1cd; border: 1px solid #f1d38b; }
.compare-check { position: absolute; right: 11px; top: 10px; z-index: 2; border: 0; border-radius: 8px; padding: 7px 8px; background: rgba(255,255,255,.9); font-size: 9px; font-weight: 800; cursor: pointer; }
.card-body { padding: 14px; }
.brand-name { margin-bottom: 5px; color: var(--brand-deep); font-size: 9px; letter-spacing: 1.3px; font-weight: 900; text-transform: uppercase; }
.device-card h3 { margin: 0; font-family: "Calistoga", Georgia, serif; font-size: 18px; font-weight: 400; letter-spacing: -.2px; }
.specs { display: flex; gap: 6px; margin: 9px 0 12px; flex-wrap: wrap; }
.specs span { padding: 5px 7px; background: var(--soft); border-radius: 5px; color: #687080; font-size: 9px; }
.price-grid { padding-top: 11px; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; border-top: 1px solid var(--line); }
.price-grid small { display: block; color: #8d929b; font-size: 8px; }
.price-grid strong { display: block; margin-top: 3px; font-size: 13px; white-space: nowrap; }
.view-button { width: 100%; margin-top: 14px; padding: 11px; border: 1px solid var(--ink); border-radius: 8px; background: white; font-size: 11px; font-weight: 850; cursor: pointer; }
.view-button:hover { color: white; border-color: var(--brand); background: var(--brand); }
.load-more-row { padding: 26px 0 0; text-align: center; }
.load-more-row button { min-width: 190px; padding: 13px 20px; border: 1px solid var(--ink); border-radius: 10px; color: white; background: var(--ink); cursor: pointer; font-size: 12px; font-weight: 850; }
.load-more-row button:hover { border-color: var(--brand); background: var(--brand); }
.empty-state { padding: 80px 20px; text-align: center; background: var(--soft); border-radius: var(--radius); }
.empty-state > span { font-size: 36px; }
.empty-state h3 { margin-bottom: 6px; }
.empty-state p { color: var(--muted); font-size: 13px; }

.drawer-backdrop { position: fixed; inset: 0; z-index: 50; background: rgba(6, 10, 17, .58); backdrop-filter: blur(4px); }
.device-drawer { position: fixed; z-index: 51; inset: 0 0 0 auto; width: min(660px, 100%); padding: 28px 32px 40px; overflow-y: auto; background: white; box-shadow: -20px 0 60px rgba(0,0,0,.2); transform: translateX(102%); transition: transform .32s ease; }
.device-drawer.open { transform: translateX(0); }
.drawer-close { position: sticky; top: 0; z-index: 5; float: right; width: 38px; height: 38px; border: 1px solid var(--line); border-radius: 50%; background: white; font-size: 24px; cursor: pointer; }
.drawer-hero { display: grid; grid-template-columns: 180px 1fr; gap: 24px; align-items: center; padding: 18px 0 27px; clear: both; }
.drawer-device-visual { height: 220px; display: grid; place-items: center; border-radius: 18px; background: var(--soft); }
.drawer-device-visual .product-phone { width: 100px; height: 193px; }
.drawer-copy .brand-name { font-size: 10px; }
.drawer-copy h2 { margin: 4px 0 9px; font-family: "Calistoga", Georgia, serif; font-size: 29px; font-weight: 400; letter-spacing: -.4px; }
.drawer-specs { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 15px; }
.drawer-specs div { padding: 10px; background: var(--soft); border-radius: 8px; }
.drawer-specs small, .drawer-specs strong { display: block; }
.drawer-specs small { color: #8a9099; font-size: 8px; text-transform: uppercase; }
.drawer-specs strong { margin-top: 3px; font-size: 11px; }
.offer-heading { display: flex; align-items: end; justify-content: space-between; gap: 15px; margin: 8px 0 12px; }
.offer-heading h3 { margin: 0; font-size: 19px; }
.offer-heading small { color: var(--muted); font-size: 9px; }
.offer-table { width: 100%; border: 1px solid var(--line); border-radius: 13px; overflow: hidden; }
.offer-row { padding: 15px; display: grid; grid-template-columns: 24px 1.2fr repeat(4, .8fr); gap: 9px; align-items: center; border-bottom: 1px solid var(--line); cursor: pointer; }
.offer-row:last-child { border-bottom: 0; }
.offer-row:hover, .offer-row.selected { background: #fff1ee; }
.offer-row input { accent-color: var(--brand-deep); }
.offer-row strong, .offer-row small { display: block; }
.offer-row strong { font-size: 11px; }
.offer-row small { margin-top: 3px; color: #838993; font-size: 8px; }
.offer-row .offer-name strong { font-size: 12px; }
.offer-row.unavailable { cursor: default; opacity: .68; background: #fafafa; }
.unavailable-note { color: #9a6211 !important; }
.selection-summary { margin-top: 15px; padding: 15px; display: flex; justify-content: space-between; gap: 20px; align-items: center; border-radius: 10px; background: var(--ink); color: white; }
.selection-summary span { font-size: 10px; color: #b7bdc8; }
.selection-summary strong { display: block; margin-top: 3px; font-size: 13px; }
.selection-summary button { flex: 0 0 auto; background: var(--brand); color: var(--ink); }
.terms-note { margin: 13px 0 0; color: #858b95; font-size: 9px; line-height: 1.55; }
.availability-card { padding: 20px; border: 1px solid #ffc4b9; background: #fff2ef; border-radius: 13px; }
.availability-card h3 { margin: 0 0 5px; font-size: 17px; }
.availability-card p { color: #742313; font-size: 11px; line-height: 1.5; }
.toast { position: fixed; z-index: 100; right: 22px; bottom: 22px; max-width: 330px; padding: 12px 16px; border-radius: 10px; color: white; background: var(--ink); box-shadow: var(--shadow); font-size: 12px; transform: translateY(80px); opacity: 0; transition: .25s; }
.toast.show { transform: translateY(0); opacity: 1; }
body.drawer-open { overflow: hidden; }

@media (max-width: 1060px) {
  .device-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

@media (max-width: 760px) {
  .site-header { height: 62px; padding: 0 14px; }
  .brand img { width: 154px; }
  .header-support { padding: 9px 12px; font-size: 10px; }
  .catalogue-section { min-height: calc(100vh - 62px); padding: 20px 14px 88px; }
  .section-heading { margin-bottom: 12px; }
  .section-heading h1 { font-size: 25px; letter-spacing: -.8px; }
  .catalogue-tools { top: 62px; padding: 8px 0; margin-bottom: 12px; }
  .filter-toggle { display: block; }
  .catalogue-layout { grid-template-columns: 1fr; }
  .filters { display: none; padding: 0 16px; border: 1px solid var(--line); border-radius: 12px; }
  .filters.open { display: block; }
  .device-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
  .device-image { height: 165px; }
}

@media (max-width: 500px) {
  .search-box { padding: 0 11px; }
  .search-box input { font-size: 12px; }
  .filter-toggle { padding: 0 12px; font-size: 11px; }
  .results-meta { align-items: center; }
  .results-meta label { font-size: 0; }
  .results-meta select { margin-left: 0; font-size: 10px; }
  .device-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 9px; }
  .device-image { height: 145px; }
  .product-phone { width: 68px; height: 132px; border-radius: 13px; }
  .product-photo { width: 92%; height: 92%; }
  .card-body { padding: 11px; }
  .brand-name { font-size: 8px; }
  .device-card h3 { min-height: 34px; font-size: 14px; line-height: 1.2; }
  .specs { gap: 4px; margin: 7px 0 10px; }
  .specs span { padding: 4px 5px; font-size: 8px; }
  .price-grid { grid-template-columns: 1fr; gap: 7px; }
  .price-grid strong { font-size: 12px; }
  .view-button { margin-top: 10px; padding: 10px 6px; font-size: 10px; }
  .device-drawer { padding: 20px 17px 35px; }
  .drawer-hero { grid-template-columns: 120px 1fr; gap: 16px; }
  .drawer-device-visual { height: 180px; }
  .drawer-device-visual .product-phone { width: 78px; height: 151px; }
  .drawer-copy h2 { font-size: 23px; }
  .drawer-specs { grid-template-columns: 1fr; }
  .offer-row { grid-template-columns: 22px 1.2fr .9fr .9fr; }
  .offer-row .hide-mobile { display: none; }
  .selection-summary { align-items: stretch; flex-direction: column; }
}

@media (max-width: 340px) {
  .device-grid { grid-template-columns: 1fr; }
  .device-image { height: 210px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
