/* ============================================================
   ClaraMatrix — public site, login & service desk styles
   Light, water-clean palette. Warm paper, deep-teal ink,
   a splash of sea green and sun gold.
   ============================================================ */

:root {
  --paper: #f7f5ee;
  --paper-2: #efece2;
  --card: #fffdf8;
  --ink: #0c2f2b;
  --ink-soft: #4d6a66;
  --ink-faint: #8ca39f;
  --sea: #0d9488;
  --sea-deep: #0a6d63;
  --sea-wash: #dcefeb;
  --sky: #4a9fd4;
  --sky-wash: #e3eef6;
  --sun: #e09a2f;
  --sun-wash: #f9edd4;
  --line: #e5dfd2;
  --line-strong: #d4ccb9;
  --danger: #b3402e;
  --danger-wash: #f8e3dd;
  --radius: 14px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(19, 42, 38, .05), 0 4px 14px rgba(19, 42, 38, .05);
  --shadow-md: 0 2px 4px rgba(19, 42, 38, .05), 0 14px 30px rgba(19, 42, 38, .10);
  --shadow-lg: 0 4px 10px rgba(19, 42, 38, .06), 0 28px 56px rgba(19, 42, 38, .16);
  --ease: cubic-bezier(.22, 1, .36, 1);
  --ease-pop: cubic-bezier(.34, 1.56, .64, 1);
  --banner-h: 0px;
  --header-bg: rgba(247, 245, 238, .92);
  --scroll-thumb: #c9c3b4;
  --scroll-thumb-hover: #b3ab99;
  --gold-ink: #0c2f2b;
  --sun-ink: #9a6a12;
  --marquee-bg: var(--sea-deep);
  --marquee-fg: #eafffb;
  --contact-bg: var(--sea-deep);
  color-scheme: light;
}

/* ============================================================
   Dark theme — applied when the html[data-theme] attribute is set
   by theme.js (user pick or the system preference on first load).
   ============================================================ */
html[data-theme="dark"] {
  --paper: #0d1714;
  --paper-2: #101d19;
  --card: #162420;
  --ink: #e7f1ee;
  --ink-soft: #9db4ae;
  --ink-faint: #6b837c;
  --sea: #0f9486;
  --sea-deep: #3ee0c4;
  --sea-wash: rgba(20, 150, 128, .16);
  --sky: #6db9e2;
  --sky-wash: rgba(74, 159, 212, .18);
  --sun: #e9a83e;
  --sun-wash: rgba(224, 154, 47, .15);
  --sun-ink: #f0c46b;
  --line: #21332d;
  --line-strong: #2d453d;
  --danger: #ff8a75;
  --danger-wash: rgba(255, 104, 84, .16);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .25), 0 4px 14px rgba(0, 0, 0, .35);
  --shadow-md: 0 2px 4px rgba(0, 0, 0, .35), 0 14px 30px rgba(0, 0, 0, .45);
  --shadow-lg: 0 4px 10px rgba(0, 0, 0, .4), 0 28px 56px rgba(0, 0, 0, .55);
  --header-bg: rgba(13, 23, 20, .9);
  --scroll-thumb: #2c3f38;
  --scroll-thumb-hover: #3a534a;
  --marquee-bg: #12322b;
  --marquee-fg: #aef3e6;
  --contact-bg: #12322b;
  color-scheme: dark;
}

/* machine illustrations — darker bodies in the dark theme */
html[data-theme="dark"] .machine {
  background: linear-gradient(160deg, #1e302a 0%, #172420 60%, #131f1b 100%);
  box-shadow: var(--shadow-lg), inset 0 1px 0 rgba(255, 255, 255, .06), inset 0 -8px 20px rgba(0, 0, 0, .35);
}
html[data-theme="dark"] .machine-hood { background: linear-gradient(180deg, #22453d 0%, #16312a 100%); }
html[data-theme="dark"] .machine-body { background: linear-gradient(180deg, #1b2b26, #15211d); box-shadow: inset 0 1px 0 rgba(255, 255, 255, .05); }
html[data-theme="dark"] .machine-body::before { background: #2a3d37; }
html[data-theme="dark"] .gauge { border-color: #2b4039; background: #101b18; }
html[data-theme="dark"] .machine-base { background: linear-gradient(180deg, #22362f, #1a2b26); box-shadow: inset 0 1px 3px rgba(0, 0, 0, .45); }
html[data-theme="dark"] .machine-spout { background: linear-gradient(180deg, #263a34, #1e302b); }
html[data-theme="dark"] .machine-cup { border-color: rgba(255, 255, 255, .12); background: rgba(45, 212, 191, .08); box-shadow: 0 8px 18px rgba(0, 0, 0, .4); }

/* product art and product machine in the dark theme */
html[data-theme="dark"] .p-art.teal { background: radial-gradient(120% 120% at 50% 0%, #17332d 0%, #0e1f1b 100%); }
html[data-theme="dark"] .p-art.amber { background: radial-gradient(120% 120% at 50% 0%, #33291a 0%, #1f180d 100%); }
html[data-theme="dark"] .p-art.blue { background: radial-gradient(120% 120% at 50% 0%, #1b2e3b 0%, #0f1b23 100%); }
html[data-theme="dark"] .mini-machine { background: linear-gradient(165deg, #22332e, #16231e); box-shadow: 0 18px 34px rgba(0, 0, 0, .5); }
html[data-theme="dark"] .mini-machine::before { background: linear-gradient(180deg, #22453d 0%, #16312a 100%); }

/* product dialog art in the dark theme */
html[data-theme="dark"] .detail-visual.teal { background: linear-gradient(160deg, #17332d, #0d1f1b); }
html[data-theme="dark"] .detail-visual.amber { background: linear-gradient(160deg, #33291a, #1f180d); }
html[data-theme="dark"] .detail-visual.blue { background: linear-gradient(160deg, #1b2e3b, #0f1b23); }
html[data-theme="dark"] .detail-visual .big-machine { background: linear-gradient(165deg, #22332e, #16231e); box-shadow: 0 22px 40px rgba(0, 0, 0, .55); }
html[data-theme="dark"] .detail-visual .big-machine::before { background: linear-gradient(180deg, #22453d 0%, #16312a 100%); }

/* brief colour cross-fade when switching themes */
html.theme-anim, html.theme-anim *,
html.theme-anim *::before, html.theme-anim *::after {
  transition-property: background-color, color, border-color, box-shadow, fill, stroke !important;
  transition-duration: .3s !important;
  transition-timing-function: ease !important;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(90px + var(--banner-h));
}

body {
  color: var(--ink);
  background: var(--paper);
  font-family: "Manrope", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 { line-height: 1.1; letter-spacing: -0.02em; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; }
img { display: block; max-width: 100%; }
input, textarea, select { font: inherit; }

.mono {
  font-family: "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
  font-size: .82em;
}

.hidden { display: none !important; }

::selection { background: var(--sea-wash); color: var(--sea-deep); }

::-webkit-scrollbar { width: 11px; height: 11px; }
::-webkit-scrollbar-track { background: var(--paper); }
::-webkit-scrollbar-thumb { background: var(--scroll-thumb); border: 3px solid var(--paper); border-radius: 8px; }
::-webkit-scrollbar-thumb:hover { background: var(--scroll-thumb-hover); }

/* ============================================================
   Reveal-on-scroll (toggled by app.js)
   ============================================================ */
.reveal { opacity: 1; transform: none; }
.js .reveal {
  opacity: 0;
  transform: translateY(26px);
  transition: opacity .8s ease, transform .8s var(--ease);
  will-change: opacity, transform;
}
.js .reveal.in {
  opacity: 1;
  transform: none;
}

/* ============================================================
   Buttons
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 22px;
  border: 0;
  border-radius: 999px;
  font-weight: 700;
  font-size: 14px;
  line-height: 1;
  transition: transform .25s var(--ease), box-shadow .25s ease, background .25s ease, color .25s ease;
}
.btn .arr { transition: transform .25s var(--ease); }
.btn:hover .arr { transform: translateX(4px); }
.btn:active { transform: scale(.97); }
.btn:focus-visible { outline: 3px solid var(--sky-wash); outline-offset: 2px; }
.btn:disabled { opacity: .5; pointer-events: none; }

.btn-primary {
  color: #fff;
  background: var(--sea);
  box-shadow: 0 6px 18px rgba(13, 148, 136, .28);
}
.btn-primary:hover { background: var(--sea-deep); box-shadow: 0 10px 26px rgba(13, 148, 136, .34); transform: translateY(-2px); }

.btn-secondary {
  color: var(--ink);
  background: var(--card);
  border: 1px solid var(--line-strong);
  box-shadow: var(--shadow-sm);
}
.btn-secondary:hover { border-color: var(--sea); color: var(--sea-deep); transform: translateY(-2px); }

.btn-ghost {
  color: var(--ink-soft);
  background: transparent;
  padding: 10px 14px;
}
.btn-ghost:hover { color: var(--sea-deep); background: var(--sea-wash); }

.btn-danger {
  color: #fff;
  background: var(--danger);
  box-shadow: 0 6px 18px rgba(179, 64, 46, .25);
}
.btn-danger:hover { background: #932d1d; transform: translateY(-2px); }

.btn-gold {
  color: var(--gold-ink);
  background: var(--sun);
  box-shadow: 0 6px 18px rgba(224, 154, 47, .3);
}
.btn-gold:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(224, 154, 47, .38); }

.btn.loading { pointer-events: none; position: relative; }
.btn.loading .btn-text { opacity: 0; }
.btn.loading::after {
  content: '';
  position: absolute;
  width: 18px; height: 18px;
  border: 2px solid rgba(255, 255, 255, .35);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin .7s linear infinite;
}

/* ==========================================================================
   Aqua Matrix — public site, login & service desk styles
   ========================================================================== */
.theme-toggle { position: relative; }
.theme-toggle-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--card);
  color: var(--ink-soft);
  box-shadow: var(--shadow-sm);
  transition: color .2s ease, border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}
.theme-toggle-btn:hover { color: var(--sea-deep); border-color: var(--sea); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.theme-toggle-btn:active { transform: scale(.94); }
.theme-toggle-btn:focus-visible { outline: 3px solid var(--sky-wash); outline-offset: 2px; }
.theme-toggle-icon { display: inline-flex; }
.theme-toggle-icon svg { width: 18px; height: 18px; }

.theme-menu {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  min-width: 152px;
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
  box-shadow: var(--shadow-md);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .2s ease, transform .25s var(--ease), visibility .2s;
  z-index: 70;
}
.theme-toggle.open .theme-menu { opacity: 1; visibility: visible; transform: none; }
.theme-menu button {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 11px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
  transition: background .15s ease, color .15s ease;
}
.theme-menu button:hover { background: var(--sea-wash); color: var(--sea-deep); }
.theme-menu button[aria-checked="true"] { color: var(--sea-deep); }
.theme-menu button[aria-checked="true"] .t-check { opacity: 1; }
.theme-menu .t-ico { display: inline-flex; flex-shrink: 0; }
.theme-menu .t-ico svg { width: 16px; height: 16px; }
.theme-menu .t-check { display: inline-flex; margin-left: auto; opacity: 0; transition: opacity .15s ease; }
.theme-menu .t-check svg { width: 15px; height: 15px; }

.theme-toggle-corner { position: fixed; top: 26px; right: 28px; z-index: 60; }
@media (max-width: 760px) {
  .theme-toggle-corner { top: 18px; right: 16px; }
}
@media (max-width: 480px) {
  .header-actions { gap: 10px; }
}

/* ============================================================
   Announcement banner
   ============================================================ */
.site-banner {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 10px 46px;
  background: linear-gradient(90deg, var(--sun), #e0a63f, var(--sun));
  color: var(--gold-ink);
  font-size: 13px;
  font-weight: 700;
  text-align: center;
  box-shadow: var(--shadow-sm);
}
.site-banner .banner-close {
  position: absolute;
  right: 10px; top: 50%;
  transform: translateY(-50%);
  width: 26px; height: 26px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(12, 47, 43, .12);
  color: var(--ink);
  font-size: 0;
  cursor: pointer;
  transform-origin: center center;
  transition: background .2s ease, color .2s ease, transform .25s ease;
}
.site-banner .banner-close::before,
.site-banner .banner-close::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 10px;
  height: 1.5px;
  background-color: currentColor;
  border-radius: 1px;
}
.site-banner .banner-close::before {
  transform: translate(-50%, -50%) rotate(45deg);
}
.site-banner .banner-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}
.site-banner .banner-close:hover {
  background: var(--ink);
  color: #fff;
  transform: translateY(-50%) rotate(90deg);
}

body.has-banner .site-header { top: var(--banner-h); }
body.has-banner .scroll-progress { top: var(--banner-h); }

/* ============================================================
   Scroll progress bar
   ============================================================ */
.scroll-progress {
  position: fixed;
  top: 0; left: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--sea), var(--sky), var(--sun));
  z-index: 120;
}

/* ============================================================
   Header
   ============================================================ */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 18px clamp(20px, 5vw, 64px);
  transition: padding .3s ease, background .3s ease, box-shadow .3s ease;
}
.site-header.scrolled {
  padding: 12px clamp(20px, 5vw, 64px);
  background: var(--header-bg);
  backdrop-filter: blur(12px);
  box-shadow: var(--shadow-sm);
}

.logo {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: var(--ink);
}
.logo span { color: var(--sea-deep); }
.logo .drop {
  width: 9px; height: 9px;
  margin-left: 5px;
  border-radius: 50% 50% 50% 0;
  background: linear-gradient(135deg, var(--sea), var(--sky));
  transform: rotate(-45deg);
  animation: bob 2.6s ease-in-out infinite;
}

.site-nav { display: flex; gap: 4px; }
.site-nav a {
  position: relative;
  padding: 8px 14px;
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 600;
  border-radius: 999px;
  transition: color .2s ease, background .2s ease;
}
.site-nav a:hover { color: var(--sea-deep); background: var(--sea-wash); }

.header-actions { display: flex; align-items: center; gap: 18px; }
.header-phone {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--ink);
  font-weight: 700;
  font-size: 14px;
}
.header-phone .mono { color: var(--sea-deep); }
.header-phone:hover .mono { text-decoration: underline; }

/* ============================================================
   Hero
   ============================================================ */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: 40px;
  min-height: 100svh;
  padding: 150px clamp(20px, 5vw, 64px) 90px;
  overflow: hidden;
  background:
    radial-gradient(120% 90% at 85% 10%, rgba(77, 159, 212, .10), transparent 55%),
    radial-gradient(90% 70% at 8% 88%, rgba(13, 148, 136, .12), transparent 55%),
    var(--paper);
}

.hero-copy { position: relative; z-index: 2; }

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
  color: var(--sea-deep);
  font: 600 12px "SFMono-Regular", ui-monospace, Menlo, Consolas, monospace;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.eyebrow::before {
  content: '';
  width: 22px; height: 2px;
  background: var(--sun);
  border-radius: 2px;
}

.hero h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: clamp(44px, 6.2vw, 78px);
  line-height: 1.02;
  letter-spacing: -0.025em;
  color: var(--ink);
}
.hero h1 .rot {
  display: inline-block;
  color: var(--sea-deep);
  position: relative;
  white-space: nowrap;
}
.hero h1 .rot em {
  font-style: italic;
  font-weight: 500;
  color: var(--sea);
}

.hero-text {
  margin: 22px 0 30px;
  max-width: 46ch;
  color: var(--ink-soft);
  font-size: clamp(16px, 1.6vw, 18px);
}

.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px; }

.hero-note {
  width: 100%;
  margin-top: 6px;
  color: var(--ink-faint);
  font-size: 13px;
}

.trust-row {
  display: flex;
  flex-wrap: wrap;
  gap: clamp(20px, 4vw, 44px);
  margin-top: 44px;
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.trust-item strong {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(26px, 3vw, 34px);
  font-weight: 600;
  line-height: 1;
  color: var(--ink);
}
.trust-item strong .mono { color: var(--sea-deep); font-size: .55em; vertical-align: top; }
.trust-item small {
  display: block;
  margin-top: 6px;
  color: var(--ink-faint);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
}

/* Hero visual — the machine */
.hero-visual {
  position: relative;
  z-index: 2;
  min-height: 560px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.bubbles {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.machine {
  position: relative;
  width: 250px;
  padding: 56px 26px 30px;
  border-radius: 34px 34px 26px 26px;
  background: linear-gradient(160deg, #ffffff 0%, #eef3ef 60%, #e2ebe6 100%);
  box-shadow: var(--shadow-lg), inset 0 1px 0 #fff, inset 0 -8px 20px rgba(19, 42, 38, .06);
  animation: float 5s ease-in-out infinite;
}

.machine-hood {
  position: absolute;
  top: -14px; left: 50%;
  transform: translateX(-50%);
  width: 180px; height: 30px;
  border-radius: 22px 22px 10px 10px;
  background: linear-gradient(180deg, var(--ink) 0%, #16423c 100%);
  box-shadow: 0 6px 14px rgba(12, 47, 43, .25);
}
.machine-hood::before {
  content: '';
  position: absolute;
  top: 9px; left: 50%;
  transform: translateX(-50%);
  width: 44px; height: 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, .18);
}

.machine-screen {
  position: relative;
  overflow: hidden;
  height: 120px;
  border-radius: 14px;
  background: linear-gradient(180deg, #0b3d38, #072a26);
  color: #d9fff8;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, .35);
}
.machine-screen small {
  font: 600 10px "SFMono-Regular", ui-monospace, Consolas, monospace;
  letter-spacing: .28em;
  opacity: .7;
}
.machine-screen b {
  font-family: "Fraunces", Georgia, serif;
  font-size: 44px;
  font-weight: 500;
  line-height: 1.1;
  text-shadow: 0 0 24px rgba(58, 224, 200, .55);
}
.machine-screen .screen-note {
  font: 500 10px "SFMono-Regular", ui-monospace, Consolas, monospace;
  letter-spacing: .18em;
  opacity: .55;
  margin-top: 2px;
}
.machine-screen::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 30%, rgba(13, 148, 136, .5) 90%);
  opacity: .25;
}

.machine-body {
  position: relative;
  height: 150px;
  margin-top: 18px;
  border-radius: 14px;
  background: linear-gradient(180deg, #eef3ef, #e3ece7);
  box-shadow: inset 0 1px 0 #fff;
}
.machine-body::before {
  content: '';
  position: absolute;
  top: 22px; left: 50%;
  transform: translateX(-50%);
  width: 120px; height: 6px;
  border-radius: 6px;
  background: #d3dfd8;
}
.machine-body .gauge {
  position: absolute;
  top: 42px; left: 50%;
  transform: translateX(-50%);
  width: 150px; height: 64px;
  border: 2px solid #cfdbd4;
  border-radius: 8px;
  overflow: hidden;
  background: #f4f8f5;
}
.gauge .water {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 0;
  background: linear-gradient(180deg, var(--sky), var(--sea));
  animation: fillUp 4.5s ease-in-out infinite;
}
.gauge .meter {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  padding: 5px;
}
.gauge .meter span {
  width: 3px;
  background: rgba(255, 255, 255, .5);
  border-radius: 2px;
}
.gauge .meter span:nth-child(odd) { height: 40%; }
.gauge .meter span:nth-child(even) { height: 70%; }

.machine-base {
  height: 12px;
  margin-top: 16px;
  border-radius: 8px;
  background: linear-gradient(180deg, #d7e2dc, #c7d5cd);
  box-shadow: inset 0 1px 3px rgba(12, 47, 43, .18);
}

.machine-spout {
  position: absolute;
  bottom: 36px; left: -30px;
  width: 70px; height: 14px;
  border-radius: 8px;
  background: linear-gradient(180deg, #dfe8e3, #ccd9d2);
  transform: rotate(-14deg);
  box-shadow: inset 0 -2px 4px rgba(12, 47, 43, .12);
}
.machine-spout::after {
  content: '';
  position: absolute;
  left: -6px; bottom: -8px;
  width: 7px; height: 9px;
  border-radius: 0 0 4px 4px;
  background: var(--sea);
  box-shadow: 0 0 8px rgba(13, 148, 136, .5);
  animation: drip 1.8s ease-in-out infinite;
}

.machine-cup {
  position: absolute;
  bottom: -4px; left: -44px;
  width: 52px; height: 60px;
  border-radius: 0 0 10px 10px;
  border: 3px solid rgba(255, 255, 255, .85);
  border-top: 0;
  background: rgba(220, 239, 235, .6);
  overflow: hidden;
  box-shadow: 0 8px 18px rgba(19, 42, 38, .18);
}
.cup-fill {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 18%;
  background: linear-gradient(180deg, var(--sky), var(--sea));
  animation: fillCup 4.5s ease-in-out infinite;
}
.cup-fill::before {
  content: '';
  position: absolute;
  top: -5px; left: 0; right: 0;
  height: 5px;
  border-radius: 4px;
  background: rgba(255, 255, 255, .5);
}

/* floating info chips around the machine */
.float-chip {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  font-size: 13px;
  font-weight: 700;
  color: var(--ink);
  animation: float 4.5s ease-in-out infinite;
}
.float-chip b { color: var(--sea-deep); font-family: "Fraunces", Georgia, serif; font-weight: 600; }
.float-chip small { color: var(--ink-faint); font: 500 10px "SFMono-Regular", ui-monospace, monospace; }
.chip-a { top: 14%; right: 6%; animation-delay: .3s; }
.chip-b { bottom: 16%; left: 2%; animation-delay: 1.1s; }
.chip-c { top: 40%; left: 0; animation-delay: 1.8s; }
.chip-dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  background: var(--sea);
  box-shadow: 0 0 0 4px var(--sea-wash);
  animation: blink 2s ease-in-out infinite;
}

/* wave divider under the hero */
.wave-divider { position: relative; margin-top: -1px; overflow: hidden; }
.wave-divider svg { display: block; width: 200%; max-width: none; height: 70px; }
.wave-a { fill: var(--paper-2); animation: waveShift 9s linear infinite; }
.wave-b { fill: var(--sea-wash); animation: waveShift 14s linear infinite reverse; }

/* ============================================================
   Marquee
   ============================================================ */
.marquee {
  overflow: hidden;
  background: var(--marquee-bg);
  color: var(--marquee-fg);
  padding: 14px 0;
  border-top: 3px solid var(--sun);
}
.marquee-track {
  display: flex;
  gap: 44px;
  width: max-content;
  animation: scrollX 26s linear infinite;
}
.marquee span {
  display: inline-flex;
  align-items: center;
  gap: 44px;
  white-space: nowrap;
  font: 600 13px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .08em;
  text-transform: uppercase;
}
.marquee span::after {
  content: '✦';
  color: var(--sun);
  font-size: 11px;
}
.marquee-track:hover { animation-play-state: paused; }

/* ============================================================
   Sections — shared
   ============================================================ */
.section {
  padding: clamp(70px, 9vw, 120px) clamp(20px, 5vw, 64px);
}
.section-head {
  max-width: 640px;
  margin-bottom: clamp(36px, 5vw, 60px);
}
.section-head h2 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: clamp(32px, 4.5vw, 52px);
  letter-spacing: -0.02em;
  color: var(--ink);
}
.section-head h2 em {
  font-style: italic;
  color: var(--sea);
}
.section-head p {
  margin-top: 14px;
  color: var(--ink-soft);
  font-size: 16px;
  max-width: 46ch;
}
.section-head.center { margin-left: auto; margin-right: auto; text-align: center; }
.section-head.center p { margin-left: auto; margin-right: auto; }
.section-head.center .eyebrow::before { display: none; }
.section-head.center .eyebrow::after {
  content: '';
  width: 22px; height: 2px;
  background: var(--sun);
  border-radius: 2px;
}

/* ============================================================
   Products
   ============================================================ */
.product-section { background: var(--paper-2); }

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 26px;
  max-width: 1100px;
  margin: 0 auto;
}

.p-card {
  perspective: 1200px;
  transform-style: preserve-3d;
}
.p-card-btn {
  display: block;
  width: 100%;
  border: 0;
  border-radius: var(--radius-lg);
  background: var(--card);
  box-shadow: var(--shadow-sm);
  text-align: left;
  overflow: hidden;
  transition: box-shadow .35s ease, transform .35s var(--ease);
  transform: translateZ(0);
}
.p-card:hover .p-card-btn { box-shadow: var(--shadow-md); }

.p-art {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 250px;
  overflow: hidden;
}
.p-art.teal { background: radial-gradient(120% 120% at 50% 0%, #e6f4f0 0%, #cfe8e1 100%); }
.p-art.amber { background: radial-gradient(120% 120% at 50% 0%, #fbf0da 0%, #f3e0bb 100%); }
.p-art.blue { background: radial-gradient(120% 120% at 50% 0%, #e4f0f8 0%, #cfe3f0 100%); }

.p-tag {
  position: absolute;
  top: 16px; left: 16px;
  padding: 5px 12px;
  border-radius: 999px;
  background: var(--card);
  border: 1px solid var(--line);
  color: var(--sea-deep);
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .04em;
  text-transform: uppercase;
  box-shadow: var(--shadow-sm);
}

.mini-machine {
  position: relative;
  width: 96px; height: 168px;
  border-radius: 16px 16px 20px 20px;
  background: linear-gradient(165deg, #ffffff, #e8f0eb);
  box-shadow: 0 18px 34px rgba(19, 42, 38, .22);
  transition: transform .4s var(--ease-pop);
}
.p-card:hover .mini-machine { transform: translateY(-8px) rotate(-2deg); }
.mini-machine::before {
  content: '';
  position: absolute;
  top: -8px; left: 50%;
  transform: translateX(-50%);
  width: 68px; height: 16px;
  border-radius: 12px 12px 4px 4px;
  background: linear-gradient(180deg, var(--ink), #16423c);
}
.mini-machine::after {
  content: '';
  position: absolute;
  top: 30px; left: 50%;
  transform: translateX(-50%);
  width: 52px; height: 46px;
  border-radius: 8px;
  background: linear-gradient(180deg, #0b3d38, #072a26);
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, .35);
}
.p-card:hover .mini-machine::after {
  box-shadow: inset 0 2px 8px rgba(0, 0, 0, .35), 0 0 16px rgba(13, 148, 136, .5);
}
.mini-machine .mini-screen {
  position: absolute;
  top: 32px; left: 50%;
  transform: translateX(-50%);
  width: 46px; height: 42px;
  border-radius: 7px;
  background: radial-gradient(circle at 50% 45%, rgba(80, 230, 205, .35), transparent 70%), #0a352f;
  z-index: 1;
}

.p-view {
  position: absolute;
  right: 16px; bottom: 16px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--sea);
  color: #fff;
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  text-transform: uppercase;
  letter-spacing: .05em;
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .3s ease, transform .3s var(--ease);
}
.p-card:hover .p-view { opacity: 1; transform: none; }

.p-copy { padding: 22px 24px 24px; }
.p-copy small {
  color: var(--sea-deep);
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  text-transform: uppercase;
  letter-spacing: .1em;
}
.p-copy h3 {
  margin: 6px 0 8px;
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: 22px;
  color: var(--ink);
}
.p-copy p {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.55;
}
.p-feats {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 14px 0 16px;
}
.p-feats li {
  list-style: none;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--sea-wash);
  color: var(--sea-deep);
  font-size: 12px;
  font-weight: 600;
}
.p-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--sea-deep);
  font-weight: 700;
  font-size: 14px;
}
.p-link i { font-style: normal; transition: transform .25s var(--ease); }
.p-card:hover .p-link i { transform: translateX(5px); }

/* ============================================================
   How it works
   ============================================================ */
.how-section { background: var(--paper); }

.how-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
  max-width: 1100px;
  margin: 0 auto;
}
.how-card {
  position: relative;
  padding: 30px 26px;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  transition: transform .35s var(--ease), box-shadow .35s ease, border-color .3s ease;
}
.how-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.how-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px; height: 44px;
  margin-bottom: 18px;
  border-radius: 12px;
  background: var(--sea-wash);
  color: var(--sea-deep);
  font: 600 15px "SFMono-Regular", ui-monospace, monospace;
  transition: background .3s ease, color .3s ease, transform .3s var(--ease-pop);
}
.how-card:hover .how-num { background: var(--sea); color: #fff; transform: rotate(-6deg) scale(1.05); }
.how-card h3 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: 20px;
  margin-bottom: 8px;
}
.how-card p { color: var(--ink-soft); font-size: 14.5px; line-height: 1.6; }

/* ============================================================
   Quote band
   ============================================================ */
.quote-band {
  position: relative;
  padding: clamp(60px, 8vw, 100px) clamp(20px, 5vw, 64px);
  text-align: center;
  background:
    radial-gradient(80% 100% at 50% 0%, rgba(13, 148, 136, .10), transparent 60%),
    var(--paper-2);
  overflow: hidden;
}
.quote-band blockquote {
  max-width: 760px;
  margin: 0 auto;
  font-family: "Fraunces", Georgia, serif;
  font-size: clamp(22px, 3.4vw, 34px);
  font-weight: 500;
  line-height: 1.35;
  color: var(--ink);
}
.quote-band blockquote em {
  font-style: italic;
  color: var(--sea-deep);
}
.quote-band cite {
  display: block;
  margin-top: 22px;
  font-style: normal;
  color: var(--ink-faint);
  font-size: 14px;
}
.quote-band cite::before {
  content: '— ';
  color: var(--sun);
}
.quote-band .stars { color: var(--sun); font-size: 15px; letter-spacing: 4px; }

/* ============================================================
   Reviews
   ============================================================ */
.reviews-section {
  background: var(--paper);
  padding: clamp(60px, 8vw, 100px) clamp(20px, 5vw, 64px);
}
.reviews-section .section-head { max-width: 680px; margin: 0 auto 40px; }
.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 24px;
  margin-bottom: 48px;
}
.review-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  transition: transform .3s var(--ease), box-shadow .3s ease, border-color .2s ease;
}
.review-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--line-strong); }
.review-card.loading { pointer-events: none; }
.review-skeleton {
  display: flex; flex-direction: column; gap: 12px;
}
.review-skeleton::before {
  content: ''; height: 20px; width: 60%; background: linear-gradient(90deg, var(--paper-2), var(--line), var(--paper-2)); border-radius: 999px; animation: shimmer 1.5s infinite;
}
.review-skeleton::after {
  content: ''; height: 60px; width: 100%; background: linear-gradient(90deg, var(--paper-2), var(--line), var(--paper-2)); border-radius: var(--radius); animation: shimmer 1.5s infinite;
}
@keyframes shimmer { 0% { background-position: -200% 0; } 100% { background-position: 200% 0; } }
.review-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 10px; flex-wrap: wrap;
}
.review-stars { color: var(--sun); font-size: 18px; letter-spacing: 2px; line-height: 1; }
.review-title { font-weight: 600; color: var(--ink); font-size: 15px; margin-bottom: 8px; }
.review-body { color: var(--ink-soft); font-size: 14px; line-height: 1.6; }
.review-footer { display: flex; align-items: center; justify-content: space-between; margin-top: 16px; padding-top: 16px; border-top: 1px dashed var(--line); }
.review-author { display: flex; align-items: center; gap: 10px; }
.review-avatar {
  width: 36px; height: 36px; border-radius: 50%; background: var(--sea); color: #fff;
  display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 14px;
}
.review-name { font-weight: 600; color: var(--ink); font-size: 13px; }
.review-date { color: var(--ink-faint); font-size: 11px; }

.review-form {
  max-width: 680px; margin: 0 auto; padding: 32px;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius-lg);
}
.review-form-head { text-align: center; margin-bottom: 24px; }
.review-form-head h3 { font-family: "Fraunces", Georgia, serif; font-size: 22px; color: var(--ink); margin-bottom: 6px; }
.review-form-head p { color: var(--ink-faint); font-size: 14px; }
.star-rating { display: flex; gap: 6px; margin-top: 8px; }
.star-rating .star {
  background: none; border: 0; font-size: 28px; color: var(--line); cursor: pointer;
  transition: transform .2s var(--ease-pop), color .2s ease;
  padding: 0 2px; line-height: 1;
}
.star-rating .star:hover, .star-rating .star.active { color: var(--sun); transform: scale(1.15); }
.star-rating .star:focus-visible { outline: 2px solid var(--sea); border-radius: 4px; }
.review-note { text-align: center; margin-top: 16px; color: var(--ink-faint); font-size: 12px; }

/* Admin reviews panel */
/* Admin reviews panel */
.reviews-admin-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 24px 26px;
}
.review-admin-card {
  display: flex;
  gap: 20px;
  align-items: flex-start;
  justify-content: space-between;
  padding: 22px 24px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: all .2s ease;
}
.review-admin-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--line-strong);
}
.review-admin-main {
  flex: 1;
  min-width: 0;
}
.review-admin-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}
.review-admin-stars {
  color: var(--sun);
  font-size: 17px;
  letter-spacing: 2px;
  line-height: 1;
}
.review-admin-title {
  font-weight: 700;
  font-size: 15px;
  color: var(--ink);
}
.review-admin-body {
  color: var(--ink-soft);
  font-size: 13.5px;
  line-height: 1.6;
  margin-top: 6px;
}
.review-admin-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  margin-top: 12px;
  font-size: 12px;
  color: var(--ink-faint);
  padding-top: 10px;
  border-top: 1px dashed var(--line-faint);
}
.review-admin-meta span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.review-admin-badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font: 700 10.5px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.review-admin-badge.pending { background: var(--sun-wash); color: var(--sun-ink); border: 1px solid var(--sun); }
.review-admin-badge.approved { background: var(--sea-wash); color: var(--sea-deep); border: 1px solid var(--sea); }
.review-admin-badge.rejected { background: var(--danger-wash); color: var(--danger); border: 1px solid var(--danger); }
.review-admin-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
  min-width: 110px;
}
.review-admin-actions .service-btn {
  font-size: 12px;
  padding: 8px 14px;
  justify-content: center;
  width: 100%;
  margin: 0;
}
@media (max-width: 768px) {
  .review-admin-card {
    flex-direction: column;
  }
  .review-admin-actions {
    flex-direction: row;
    width: 100%;
    margin-top: 12px;
  }
}

/* ============================================================
   Contact
   ============================================================ */
.contact-section { background: var(--contact-bg); color: #eafffb; }
.contact-section .eyebrow { color: var(--sun); }
.contact-section .section-head h2 { color: #fff; }
.contact-section .section-head h2 em { color: var(--sun); }
.contact-section .section-head p { color: rgba(234, 255, 251, .75); }

.contact-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  max-width: 1000px;
  margin: 0 auto;
}
.contact-card {
  padding: 26px;
  border-radius: var(--radius-lg);
  background: rgba(255, 255, 255, .06);
  border: 1px solid rgba(255, 255, 255, .14);
  transition: background .3s ease, transform .3s var(--ease);
}
.contact-card:hover { background: rgba(255, 255, 255, .1); transform: translateY(-4px); }
.contact-card .cc-label {
  display: block;
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--sun);
  margin-bottom: 10px;
}
.contact-card .cc-value {
  font-size: 18px;
  font-weight: 700;
  color: #fff;
}
.contact-card .cc-sub {
  display: block;
  margin-top: 6px;
  font-size: 13px;
  color: rgba(234, 255, 251, .65);
}
.contact-card a.cc-value:hover { text-decoration: underline; }

/* ============================================================
   Footer
   ============================================================ */
.site-footer {
  padding: 40px clamp(20px, 5vw, 64px);
  background: #08231f;
  color: rgba(234, 255, 251, .65);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}
.site-footer .logo { color: #fff; }
.site-footer .logo span { color: #58dccb; }
.site-footer p { font-size: 13px; }
.site-footer a:hover { color: #fff; }

/* ============================================================
   Product detail dialog (public)
   ============================================================ */
dialog {
  border: 0;
  border-radius: var(--radius-lg);
  background: var(--card);
  color: var(--ink);
  padding: 0;
  margin: auto;
  width: min(720px, calc(100vw - 32px));
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-lg);
}
dialog::backdrop {
  background: rgba(12, 35, 31, .55);
  backdrop-filter: blur(4px);
}
dialog[open] { animation: dialogIn .32s var(--ease); }

.product-detail { text-align: center; }
.product-detail .detail-visual {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  padding: 26px 26px 6px;
}
.product-detail .detail-copy { position: relative; padding: 18px 34px 34px; }
.product-detail .detail-copy .eyebrow { justify-content: center; }
.product-detail .detail-copy h2 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: 30px;
  margin: 4px 0 12px;
}
.product-detail .detail-copy > p { color: var(--ink-soft); font-size: 14.5px; line-height: 1.6; }
.product-detail .detail-copy h3 {
  margin: 22px 0 10px;
  font-size: 13px;
  color: var(--sea-deep);
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 700;
}
.product-detail .detail-copy ul { list-style: none; display: flex; flex-direction: column; gap: 8px; }
.product-detail .detail-copy li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
  color: var(--ink-soft);
  font-size: 14px;
}
.product-detail .detail-copy li::before {
  content: '✓';
  color: var(--sea);
  font-weight: 800;
}

.close-modal {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: var(--paper-2);
  color: var(--ink-soft);
  cursor: pointer;
  flex-shrink: 0;
  padding: 0;
  position: relative;
  font-size: 0; /* hide text baseline shift */
  transform-origin: center center;
  transition: background .2s ease, color .2s ease, transform .25s cubic-bezier(0.4, 0, 0.2, 1);
  box-sizing: border-box;
}
.close-modal::before,
.close-modal::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 14px;
  height: 2px;
  background-color: currentColor;
  border-radius: 2px;
  transform-origin: center center;
  transition: background-color .2s ease;
}
.close-modal::before {
  transform: translate(-50%, -50%) rotate(45deg);
}
.close-modal::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.close-modal:hover {
  background: var(--danger);
  color: #fff;
  transform: rotate(90deg) scale(1.06);
}
.detail-copy .close-modal { position: absolute; top: 14px; right: 14px; }

.detail-visual.teal { background: linear-gradient(160deg, #e0f3ee, #cbe7e0); }
.detail-visual.amber { background: linear-gradient(160deg, #faeeda, #f1dbb4); }
.detail-visual.blue { background: linear-gradient(160deg, #e1eef7, #cbe0ee); }
.detail-visual .big-machine {
  width: 140px; height: 220px;
  border-radius: 20px 20px 26px 26px;
  background: linear-gradient(165deg, #ffffff, #e4ede8);
  box-shadow: 0 22px 40px rgba(19, 42, 38, .25);
  position: relative;
}
.detail-visual .big-machine::before {
  content: '';
  position: absolute;
  top: -10px; left: 50%;
  transform: translateX(-50%);
  width: 96px; height: 20px;
  border-radius: 14px 14px 6px 6px;
  background: linear-gradient(180deg, var(--ink), #16423c);
}
.detail-visual .big-machine::after {
  content: '';
  position: absolute;
  top: 40px; left: 50%;
  transform: translateX(-50%);
  width: 70px; height: 62px;
  border-radius: 10px;
  background: radial-gradient(circle at 50% 40%, rgba(80, 230, 205, .4), transparent 75%), #0a352f;
  box-shadow: inset 0 2px 10px rgba(0, 0, 0, .35);
}

.gallery-stage { position: relative; width: 100%; }
.gallery-main {
  width: 100%;
  height: min(50vh, 380px);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--paper-2);
  border: 1px solid var(--line);
}
.gallery-main img { width: 100%; height: 100%; object-fit: contain; }
.gallery-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 42px; height: 42px;
  border: 0;
  border-radius: 50%;
  background: var(--card);
  color: var(--ink);
  font-size: 24px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--shadow-md);
  z-index: 2;
  transition: background .2s ease, color .2s ease, transform .2s ease;
}
.gallery-nav.prev { left: 12px; }
.gallery-nav.next { right: 12px; }
.gallery-nav:hover { background: var(--sea); color: #fff; transform: translateY(-50%) scale(1.08); }
.gallery-nav:disabled { opacity: 0; pointer-events: none; }
.gallery-thumbs { display: flex; gap: 8px; flex-wrap: wrap; justify-content: center; }
.gallery-thumb {
  width: 54px; height: 54px;
  padding: 0;
  border-radius: 10px;
  border: 2px solid var(--line);
  overflow: hidden;
  background: var(--paper-2);
  transition: border-color .2s ease, transform .2s ease;
}
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; }
.gallery-thumb:hover { transform: translateY(-2px); }
.gallery-thumb.active { border-color: var(--sea); box-shadow: 0 0 0 3px var(--sea-wash); }

/* ============================================================
   Login page
   ============================================================ */
.login-page {
  position: relative;
  min-height: 100vh;
  display: grid;
  place-items: safe center;
  padding: 60px 20px;
  background:
    radial-gradient(100% 70% at 15% 10%, rgba(13, 148, 136, .12), transparent 55%),
    radial-gradient(80% 60% at 90% 90%, rgba(74, 159, 212, .12), transparent 55%),
    var(--paper);
  overflow-x: hidden;
  overflow-y: auto;
}
.login-logo {
  position: static;
  margin: 0 auto 26px;
}
.login-card {
  position: relative;
  width: min(460px, 100%);
  padding: 44px;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
  animation: cardIn .5s var(--ease);
}
.login-card h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: 36px;
  letter-spacing: -0.02em;
  margin-bottom: 6px;
}
.login-card > p:not(.eyebrow) {
  color: var(--ink-soft);
  font-size: 15px;
  margin-bottom: 28px;
}
.login-card form { display: grid; gap: 18px; }

.login-card label,
.form-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: var(--ink-soft);
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.login-card input,
.form-grid input,
.form-grid textarea,
.form-grid select {
  width: 100%;
  padding: 13px 14px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  color: var(--ink);
  font-size: 15px;
  font-weight: 500;
  transition: border-color .2s ease, box-shadow .2s ease, background .2s ease;
}
.login-card input::placeholder,
.form-grid input::placeholder,
.form-grid textarea::placeholder { color: var(--ink-faint); }
.login-card input:focus,
.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus {
  outline: none;
  border-color: var(--sea);
  box-shadow: 0 0 0 4px var(--sea-wash);
  background: var(--card);
}
.login-card input:hover,
.form-grid input:hover,
.form-grid textarea:hover,
.form-grid select:hover { border-color: var(--line-strong); }

.login-card .btn-primary { width: 100%; margin-top: 6px; padding: 15px; font-size: 15px; }
.login-card small {
  display: block;
  margin-top: 26px;
  color: var(--ink-faint);
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}
.login-card small code {
  background: var(--sea-wash);
  color: var(--sea-deep);
  padding: 2px 6px;
  border-radius: 6px;
  font-size: 11px;
}

/* Enhanced Register Card & Form Grid */
.login-card.register-card {
  width: min(540px, 100%);
  padding: 40px 42px;
}
.register-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 4px;
}
.register-grid .wide {
  grid-column: span 2;
}
.reg-step-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 22px;
}
.reg-step-item {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-faint);
  transition: all .2s ease;
}
.reg-step-item.active {
  background: var(--sea-wash);
  border-color: rgba(13, 148, 136, .3);
  color: var(--sea-deep);
  font-weight: 700;
}
.reg-step-num {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--line);
  color: var(--ink-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 800;
}
.reg-step-item.active .reg-step-num {
  background: var(--sea);
  color: #fff;
}
.reg-otp-card {
  margin-top: 8px;
  padding: 20px;
  background: var(--paper-2);
  border: 1.5px solid var(--sea-border, rgba(13, 148, 136, .25));
  border-radius: 14px;
  box-shadow: 0 4px 16px rgba(13, 148, 136, .05);
  animation: cardIn .35s ease;
}
.reg-otp-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}
.reg-otp-icon {
  font-size: 22px;
}
.reg-otp-title {
  font-size: 14.5px;
  font-weight: 700;
  color: var(--ink);
}
.reg-otp-sub {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 14px;
  line-height: 1.45;
}
.reg-otp-sub b {
  color: var(--sea-deep);
}
.reg-otp-input {
  font-family: "SFMono-Regular", ui-monospace, monospace !important;
  letter-spacing: 6px !important;
  font-size: 20px !important;
  font-weight: 800 !important;
  text-align: center !important;
  background: var(--card) !important;
  border-color: var(--sea) !important;
  padding: 12px 14px !important;
}

@media (max-width: 580px) {
  .login-card.register-card {
    padding: 32px 20px;
  }
  .register-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .register-grid .wide {
    grid-column: span 1;
  }
}

.form-error {
  min-height: 18px;
  margin: 0;
  color: var(--danger);
  font-size: 13px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}
.form-error::before {
  content: '!';
  width: 18px; height: 18px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--danger-wash);
  color: var(--danger);
  font-size: 11px;
  font-weight: 800;
}

/* ============================================================
   Service desk — dashboard
   ============================================================ */
.dashboard {
  min-height: 100vh;
  padding: 40px clamp(20px, 5vw, 64px) 80px;
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(74, 159, 212, .07), transparent 55%),
    var(--paper);
}
.dash-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding: 10px 0 24px;
  border-bottom: 1px solid var(--line);
}
.dash-top .btn-ghost { margin-left: -14px; }
.dash-brand {
  color: var(--ink-faint);
  font: 600 12px "SFMono-Regular", ui-monospace, monospace;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.dash-brand b { color: var(--sea-deep); }
.dash-top .btn-group { display: flex; gap: 10px; }
.dash-intro { margin: 48px 0 36px; }
.dash-intro h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: clamp(34px, 4.5vw, 50px);
  letter-spacing: -0.02em;
}
.dash-intro em { font-style: italic; color: var(--sea); }
.dash-intro > p:last-child { margin-top: 8px; color: var(--ink-soft); font-size: 15px; }

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 18px;
  margin-bottom: 34px;
}
.stat {
  position: relative;
  padding: 24px;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  transition: transform .3s var(--ease), box-shadow .3s ease, border-color .3s ease;
}
.stat::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, var(--sea), var(--sky));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .4s var(--ease);
}
.stat:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.stat:hover::before { transform: scaleX(1); }
.stat small {
  display: block;
  color: var(--ink-faint);
  font: 600 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 8px;
}
.stat strong {
  display: block;
  font-family: "Fraunces", Georgia, serif;
  font-size: 34px;
  font-weight: 600;
  line-height: 1;
  margin-bottom: 6px;
}
.stat span { color: var(--ink-soft); font-size: 12.5px; }
.stat.warning::before { background: linear-gradient(90deg, var(--danger), var(--sun)); }
.stat.warning strong { color: var(--danger); }
.stat.active { border-color: var(--sea); box-shadow: 0 0 0 3px var(--sea-wash), var(--shadow-sm); }
.stat.active::before { transform: scaleX(1); }
.stat.revenue::before { background: linear-gradient(90deg, var(--sun), var(--sea)); }
.stat.revenue strong { color: var(--sea-deep); }

.client-panel,
.product-admin {
  margin-top: 22px;
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--card);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-sm);
}
.panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
}
.panel-head h2 { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 20px; }
.panel-head p { margin: 4px 0 0; color: var(--ink-faint); font-size: 13px; }

.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.search {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 14px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-faint);
  transition: border-color .2s ease, box-shadow .2s ease;
}
.search:focus-within { border-color: var(--sea); box-shadow: 0 0 0 4px var(--sea-wash); }
.search input {
  width: 230px;
  padding: 11px 0;
  border: 0;
  outline: 0;
  background: transparent;
  color: var(--ink);
  font-size: 14px;
}
.search input::placeholder { color: var(--ink-faint); }
.filters select {
  padding: 11px 14px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.filters select:hover { border-color: var(--line-strong); }
.filters select:focus { outline: none; border-color: var(--sea); box-shadow: 0 0 0 4px var(--sea-wash); }

.table-wrap { overflow-x: auto; }
table { width: 100%; min-width: 840px; border-collapse: collapse; }
th {
  padding: 14px 20px;
  color: var(--ink-faint);
  background: var(--paper-2);
  text-align: left;
  font: 600 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .1em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 16px 20px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 13.5px;
  transition: background .2s ease;
}
tbody tr { transition: background .2s ease; }
tbody tr:hover { background: var(--sea-wash); }
tbody tr:hover td { background: transparent; }
.client-name { color: var(--ink); font-weight: 700; }
.client-name small { display: block; margin-top: 3px; color: var(--ink-faint); font-weight: 500; font-size: 11.5px; }
.address-cell { max-width: 260px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.phone-link { color: var(--sea-deep); text-decoration: none; font-weight: 600; }
.phone-link:hover { text-decoration: underline; }
.map-link { color: var(--sea-deep); cursor: pointer; }
.map-link:hover { text-decoration: underline; }
.product-cell { color: var(--sea-deep); font-weight: 600; }

.status {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px;
  border-radius: 999px;
  font: 600 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; }
.status:not(.late) { color: var(--sea-deep); background: var(--sea-wash); }
.status:not(.late)::before { background: var(--sea); box-shadow: 0 0 0 3px rgba(13, 148, 136, .2); }
.status.late { color: var(--danger); background: var(--danger-wash); }
.status.late::before { background: var(--danger); box-shadow: 0 0 0 3px rgba(179, 64, 46, .15); }

.service-btn,
.danger-btn {
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--sea-deep);
  background: var(--card);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s ease;
}
.service-btn:hover {
  border-color: var(--sea);
  background: var(--sea);
  color: #fff;
  transform: translateY(-1px);
}
.danger-btn { margin-left: 8px; color: var(--danger); border-color: var(--danger); background: var(--danger-wash); }
.danger-btn:hover { background: var(--danger); color: #fff; border-color: var(--danger); transform: translateY(-1px); }

.admin-products {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 14px;
  padding: 22px 24px;
}
.admin-products > div {
  padding: 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .3s var(--ease), box-shadow .3s ease, border-color .2s ease;
}
.admin-products > div:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.admin-products b { font-size: 15px; color: var(--ink); }
.admin-products span { display: block; margin-top: 6px; color: var(--ink-faint); font-size: 12.5px; }
.admin-products .service-btn { margin-top: 16px; width: 100%; justify-content: center; }
.product-admin-actions { display: flex; gap: 8px; margin-top: 16px; }
.product-admin-actions .service-btn { margin: 0; flex: 1; justify-content: center; }

#engineerList {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
  padding: 22px 24px;
}.engineer-card {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  gap: 14px;
  min-width: 0;
  padding: 20px 22px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  transition: transform .3s var(--ease), box-shadow .3s ease;
}
.engineer-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.engineer-info { display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.engineer-info b { color: var(--ink); font-size: 15px; }
.engineer-info > span { color: var(--ink-faint); font-size: 12.5px; }
.engineer-stats { display: flex; flex-wrap: wrap; gap: 6px 14px; margin-top: 4px; }
.engineer-stats span { color: var(--ink-faint); font: 600 10px "SFMono-Regular", ui-monospace, monospace; }
.engineer-stats b { font-size: 12px; color: var(--ink); }
.engineer-actions { display: flex; gap: 8px; }
.engineer-actions .service-btn { flex: 1; justify-content: center; margin: 0; padding: 10px 8px; font-size: 11.5px; white-space: nowrap; }
.assign-select {
  flex: 1.4;
  min-width: 0;
  padding: 10px 12px;
  border: 1.5px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  color: var(--ink);
  font: 500 13px "Manrope", system-ui, sans-serif;
}
.assign-select:focus { outline: none; border-color: var(--sea); box-shadow: 0 0 0 4px var(--sea-wash); }
.edit-btn { margin-left: 8px; color: var(--sun-ink); border-color: var(--sun); background: var(--sun-wash); }
.edit-btn:hover { background: var(--sun); color: var(--ink); border-color: var(--sun); }

/* website content settings form */
/* ============================================================
   Live Website CMS Studio Layout (Horizontal Tabs & Stage)
   ============================================================ */
.cms-studio-container {
  display: flex;
  flex-direction: column;
  width: 100%;
  margin: 0;
  padding: 0;
}

.cms-tabs-bar {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 14px 24px;
  background: var(--paper-2);
  border-bottom: 1px solid var(--line);
  scrollbar-width: thin;
  align-items: center;
  -webkit-overflow-scrolling: touch;
}
.cms-tabs-bar::-webkit-scrollbar {
  height: 4px;
}
.cms-tabs-bar::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: 4px;
}

.cms-tab-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 1.5px solid var(--line);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink-soft);
  font: 600 13px "Manrope", system-ui, sans-serif;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: all .2s ease;
}
.cms-tab-btn:hover {
  background: var(--sand-wash);
  border-color: var(--line-strong);
  color: var(--ink);
}
.cms-tab-btn.active {
  background: var(--sea-wash);
  border-color: var(--sea);
  color: var(--sea-deep);
  font-weight: 700;
  box-shadow: var(--shadow-sm);
}
.cms-tab-icon {
  font-size: 16px;
  line-height: 1;
}
.cms-tab-label {
  line-height: 1;
}

.cms-editor-stage {
  padding: 30px 32px 36px;
  background: var(--card);
  width: 100%;
}
@media (max-width: 768px) {
  .cms-editor-stage {
    padding: 20px 16px 24px;
  }
}

.cms-tab-panel {
  display: none;
}
.cms-tab-panel.active {
  display: block;
  animation: cmsFadeIn .2s ease forwards;
}
@keyframes cmsFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.cms-panel-header {
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 24px;
}
.cms-section-badge {
  display: inline-block;
  font: 700 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .04em;
  background: var(--sea-wash);
  color: var(--sea-deep);
  padding: 4px 10px;
  border-radius: 6px;
  margin-bottom: 8px;
}
.cms-panel-title-wrap h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--ink);
  margin: 0 0 6px;
}
.cms-panel-title-wrap p {
  font-size: 13.5px;
  color: var(--ink-soft);
  margin: 0;
}

.cms-editor-stage .form-grid {
  margin-top: 18px;
}
.cms-editor-stage input[name="pageTitle"] {
  font-weight: 600;
}
.settings-save-bar {
  margin-top: 32px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 16px;
  padding: 16px 20px;
  background: var(--sand-wash);
  border: 1px solid var(--line);
  border-radius: 12px;
}
.settings-save-bar .btn {
  padding: 12px 28px;
  font-weight: 700;
}
#settingsStatus {
  margin-right: auto;
  color: var(--sea-deep);
  font-size: 13.5px;
  font-weight: 700;
}
#settingsStatus::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--sun);
}

dialog form { padding: 30px; }
.modal-heading { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 8px; }
.modal-heading h2 { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 24px; }

/* Write review modal sizing & spacing */
#writeReviewDialog {
  width: min(560px, calc(100vw - 32px));
  max-width: 560px;
}
#writeReviewDialog form {
  padding: 28px 30px 32px;
}
#writeReviewDialog .modal-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  margin-bottom: 12px;
}
#writeReviewDialog .modal-heading .eyebrow {
  margin: 0 0 4px;
}
#writeReviewDialog .modal-heading h2 {
  margin: 0;
}
#writeReviewDialog .sf-star-rating {
  justify-content: center;
  display: flex;
  margin-top: 6px;
}
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin: 20px 0; }
.form-grid textarea { min-height: 84px; resize: vertical; }
.form-grid small { display: block; margin-top: 6px; color: var(--ink-faint); font-size: 11px; font-weight: 400; text-transform: none; letter-spacing: 0; }
.form-grid label > span { display: flex; align-items: center; gap: 6px; }
.form-grid label > span > small { display: inline; margin: 0; opacity: .55; font-weight: 500; }
.review-login-hint { margin: 8px 0 0; font-size: 12.5px; color: var(--ink-soft); }
.review-login-hint a { color: var(--ocean); font-weight: 600; text-decoration: underline; }
.wide { grid-column: span 2; }
.location-field { position: relative; }
.location-field button {
  padding: 8px 12px;
  border: 1px dashed var(--line-strong);
  border-radius: 999px;
  color: var(--sea-deep);
  background: var(--sea-wash);
  font-size: 11.5px;
  font-weight: 700;
  cursor: pointer;
  transition: all .2s ease;
}
.location-field button:hover { background: var(--sea); color: #fff; border-style: solid; }

.photo-preview { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.photo-preview-item {
  position: relative;
  width: 64px; height: 64px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--paper);
}
.photo-preview-item img { width: 100%; height: 100%; object-fit: cover; }
.photo-preview-item button {
  position: absolute;
  top: 4px; right: 4px;
  width: 18px; height: 18px;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(8, 35, 31, .75);
  color: #fff;
  font-size: 12px;
  line-height: 1;
  cursor: pointer;
}
.photo-preview-item button:hover { background: var(--danger); }

.form-submit { width: 100%; margin-top: 6px; padding: 15px; font-size: 15px; }

/* client detail */
#clientDetailDialog .detail-copy {
  position: relative;
  padding: 26px 30px 30px;
}
#clientDetailDialog .modal-heading { padding-right: 42px; }
#clientDetailDialog .modal-heading h2 {
  font-size: 26px;
  line-height: 1.2;
  word-break: break-word;
}
.client-detail { margin: 22px 0; }
.detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.detail-grid div { padding: 15px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.detail-grid .wide-detail { grid-column: span 2; }
.detail-grid small {
  display: block;
  color: var(--ink-faint);
  font: 600 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .1em;
  text-transform: uppercase;
  margin-bottom: 6px;
}
.detail-grid b { color: var(--ink); font-size: 14px; font-weight: 600; word-break: break-word; }
.detail-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.detail-actions .service-btn { padding: 11px 18px; font-size: 12.5px; white-space: nowrap; }

/* service history */
.history-section { margin-top: 26px; padding-top: 22px; border-top: 1px solid var(--line); }
.history-section h3 {
  margin: 0 0 14px;
  color: var(--ink-faint);
  font: 700 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.history-list { display: flex; flex-direction: column; gap: 10px; max-height: 320px; overflow-y: auto; padding-right: 4px; }
.history-item { padding: 13px 16px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--paper); }
.history-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.history-type {
  padding: 4px 10px;
  border-radius: 999px;
  font: 600 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .06em;
  text-transform: uppercase;
}
.history-type.service { color: var(--sea-deep); background: var(--sea-wash); }
.history-type.filter { color: var(--sun-ink); background: var(--sun-wash); }
.history-head b { color: var(--ink-soft); font-size: 12px; font-weight: 600; }
.history-amount { margin-left: auto; color: var(--sea-deep); font-size: 14px; font-weight: 800; }
.history-item p { margin: 9px 0 0; color: var(--ink-soft); font-size: 12.5px; line-height: 1.6; }
.history-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
  padding: 13px 16px;
  border: 1px solid var(--sea-wash);
  border-radius: var(--radius);
  background: var(--sea-wash);
  color: var(--ink-soft);
  font-size: 12.5px;
  font-weight: 600;
}
.history-total b { color: var(--sea-deep); font-size: 16px; }
.empty-history {
  margin: 0;
  padding: 18px 16px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  color: var(--ink-faint);
  font-size: 12.5px;
  text-align: center;
}

/* product dialog in dashboard */
#productDialog .detail-visual,
#productFormDialog .detail-visual { display: flex; flex-direction: column; align-items: center; justify-content: center; }

/* ============================================================
   Storefront: header links, cart button
   ============================================================ */
.header-link {
  color: var(--ink-soft);
  font-size: 14px;
  font-weight: 700;
  padding: 8px 12px;
  border-radius: 999px;
  transition: color .2s ease, background .2s ease;
}
.header-link:hover { color: var(--sea-deep); background: var(--sea-wash); }

.cart-btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px; height: 42px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--card);
  color: var(--ink-soft);
  box-shadow: var(--shadow-sm);
  transition: color .2s ease, border-color .2s ease, transform .2s ease, box-shadow .2s ease;
}
.cart-btn svg { width: 20px; height: 20px; }
.cart-btn:hover { color: var(--sea-deep); border-color: var(--sea); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.cart-btn:active { transform: scale(.94); }
.cart-count {
  position: absolute;
  top: -5px; right: -5px;
  min-width: 20px; height: 20px;
  padding: 0 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  background: var(--sea);
  color: #fff;
  font: 700 11px "SFMono-Regular", ui-monospace, monospace;
  box-shadow: 0 2px 6px rgba(13, 148, 136, .4);
  opacity: 0;
  transform: scale(.6);
  transition: opacity .2s ease, transform .2s var(--ease-pop);
}
.cart-btn.has-items .cart-count { opacity: 1; transform: scale(1); }

@media (max-width: 760px) {
  .header-link { display: none; }
}

/* ============================================================
   Product cards — price row + add to cart
   ============================================================ */
.p-card-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 14px 20px 20px;
  border-top: 1px solid var(--line);
}
.p-price {
  font-family: "Fraunces", Georgia, serif;
  font-size: 20px;
  font-weight: 600;
  color: var(--ink);
}
.p-request {
  color: var(--ink-faint);
  font: 600 11px "SFMono-Regular", ui-monospace, monospace;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.btn-sm { padding: 10px 16px; font-size: 13px; }

.detail-price {
  font-family: "Fraunces", Georgia, serif;
  font-size: 26px;
  font-weight: 600;
  color: var(--sea-deep);
  margin: 0 0 10px;
}
.detail-buy { margin-top: 24px; }
.detail-request-note {
  color: var(--ink-faint);
  font-size: 13px;
  font-weight: 600;
}

/* ============================================================
   Cart dialog
   ============================================================ */
#cartDialog { width: min(500px, calc(100vw - 32px)); }
.cart-dialog, .checkout-dialog { padding: 28px 30px 30px; }
.cart-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 18px;
}
.cart-head h2 { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 26px; }
.cart-items { display: flex; flex-direction: column; gap: 10px; max-height: 45vh; overflow-y: auto; }
.cart-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.cart-item-copy { flex: 1; min-width: 0; }
.cart-item-copy b { display: block; color: var(--ink); font-size: 14px; }
.cart-item-copy span { color: var(--ink-faint); font-size: 12.5px; }
.cart-qty { display: flex; align-items: center; gap: 8px; }
.cart-qty button {
  width: 28px; height: 28px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: var(--card);
  color: var(--sea-deep);
  font-size: 15px;
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.cart-qty button:hover { background: var(--sea); border-color: var(--sea); color: #fff; }
.cart-qty b { min-width: 20px; text-align: center; color: var(--ink); font-size: 14px; }
.cart-line-total { color: var(--ink); font-size: 14px; font-weight: 700; font-style: normal; white-space: nowrap; }
.cart-remove {
  width: 26px; height: 26px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--ink-faint);
  font-size: 16px;
  line-height: 1;
  transition: background .2s ease, color .2s ease;
}
.cart-remove:hover { background: var(--danger-wash); color: var(--danger); }
.cart-empty {
  padding: 34px 20px;
  text-align: center;
  color: var(--ink-faint);
  font-size: 14px;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.cart-empty small { font-weight: 500; font-size: 12.5px; }
.cart-foot {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.cart-total { display: flex; flex-direction: column; }
.cart-total span { color: var(--ink-faint); font: 600 10px "SFMono-Regular", ui-monospace, monospace; letter-spacing: .1em; text-transform: uppercase; }
.cart-total b { font-family: "Fraunces", Georgia, serif; font-size: 26px; font-weight: 600; color: var(--sea-deep); }

/* ============================================================
   Checkout dialog
   ============================================================ */
#checkoutDialog { width: min(520px, calc(100vw - 32px)); }
.checkout-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 16px;
  border-radius: var(--radius);
  background: var(--sea-wash);
  color: var(--ink-soft);
  font-size: 13.5px;
  font-weight: 600;
  margin: 4px 0 14px;
}
.checkout-summary b { color: var(--sea-deep); font-size: 20px; font-family: "Fraunces", Georgia, serif; }
.checkout-note {
  margin: 0 0 14px;
  color: var(--ink-faint);
  font-size: 12.5px;
  line-height: 1.6;
}

/* ============================================================
   Customer account dashboard
   ============================================================ */
.account-page .dash-brand b { color: var(--sun); }
.status.warning { color: var(--sun-ink); background: var(--sun-wash); }
.status.warning::before { background: var(--sun); box-shadow: 0 0 0 3px rgba(224, 154, 47, .2); }

.account-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 22px 24px;
}
.order-card {
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
}
.order-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.order-head b { color: var(--ink); font-size: 15px; }
.order-head span:not(.status) { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 12px; }
.order-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 13.5px;
}
.order-item b { color: var(--ink); font-weight: 600; font-size: 13px; }
.order-item em { margin-left: auto; color: var(--ink); font-style: normal; font-weight: 700; }
.order-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 12px;
  margin-top: 4px;
  border-top: 1px solid var(--line);
  color: var(--ink-soft);
  font-size: 13px;
  font-weight: 600;
}
.order-total b { color: var(--sea-deep); font-size: 18px; font-family: "Fraunces", Georgia, serif; }
.order-address { margin: 10px 0 0; color: var(--ink-faint); font-size: 12px; }
.order-note { margin: 8px 0 0; color: var(--sun-ink); font-size: 12.5px; font-weight: 600; }
.order-card > p:not(.order-address):not(.order-note) { margin: 10px 0 0; color: var(--ink-soft); font-size: 13.5px; line-height: 1.6; }
.request-contact { margin: 12px 0 0; padding-top: 12px; border-top: 1px dashed var(--line); display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; }
.request-contact b { color: var(--ink); font-size: 13px; }
.request-contact .phone-link { font-size: 13px; font-weight: 600; }
.request-contact small { display: inline; margin: 0; color: var(--ink-faint); font-size: 11px; text-transform: none; letter-spacing: 0; font-family: "Manrope", system-ui, sans-serif; font-weight: 500; width: 100%; }
.service-card .engineer-actions { justify-content: flex-start; }

/* service request groups (customer account + service desk) */
.request-groups { display: flex; flex-direction: column; gap: 26px; padding: 22px 24px; }
.request-group-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}
.request-group-head h3 { font-family: "Fraunces", Georgia, serif; font-weight: 600; font-size: 16px; color: var(--ink); }
.count-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 26px;
  height: 26px;
  padding: 0 8px;
  border-radius: 999px;
  background: var(--sea-wash);
  color: var(--sea-deep);
  font: 700 12px "SFMono-Regular", ui-monospace, monospace;
}
.request-group .request-group-head + .account-list,
.request-group .request-group-head + .request-grid { padding-top: 0; }
.request-grid { padding: 0; }
.request-card {
  padding: 18px 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--paper);
  transition: transform .3s var(--ease), box-shadow .3s ease, border-color .2s ease;
}
.request-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); border-color: var(--line-strong); }
.request-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.request-title b { display: block; color: var(--ink); font-size: 15px; }
.request-title span { display: block; margin-top: 2px; color: var(--ink-faint); font-size: 12px; }
.request-issue { margin: 10px 0 0; color: var(--ink-soft); font-size: 13.5px; line-height: 1.6; }
.request-address { margin: 8px 0 0; color: var(--ink-faint); font-size: 12px; }
.request-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px; height: 34px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--sea);
  color: #fff;
  font: 700 14px "Manrope", system-ui, sans-serif;
}
.request-contact { margin: 12px 0 0; padding-top: 12px; border-top: 1px dashed var(--line); display: flex; align-items: flex-start; gap: 10px; }
.request-contact > div { display: flex; align-items: center; flex-wrap: wrap; gap: 4px 10px; }
.request-contact b { color: var(--ink); font-size: 13px; }
.request-contact .phone-link { font-size: 13px; font-weight: 600; }
.request-contact small { display: block; width: 100%; margin: 0; color: var(--ink-faint); font-size: 11px; font-weight: 500; }
.request-card-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.request-meta { font-size: 12px; }
.request-empty {
  grid-column: 1 / -1;
  margin: 0;
  padding: 18px 16px;
  border: 1px dashed var(--line-strong);
  border-radius: var(--radius);
  color: var(--ink-faint);
  font-size: 12.5px;
  text-align: center;
}

/* admin orders & requests */
.order-item-line { display: block; font-size: 12.5px; }

/* ============================================================
   Smart Water TDS Advisor
   ============================================================ */
.advisor-section {
  background: var(--sand-wash);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.advisor-card {
  max-width: 980px;
  margin: 0 auto;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.advisor-sources {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: var(--sand);
  border-bottom: 1px solid var(--line);
}
.advisor-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 20px 16px;
  background: transparent;
  border: 0;
  border-right: 1px solid var(--line);
  cursor: pointer;
  transition: all .2s ease;
  color: var(--ink-soft);
}
.advisor-tab:last-child { border-right: 0; }
.advisor-tab .source-icon { font-size: 24px; margin-bottom: 6px; }
.advisor-tab b { font-size: 14.5px; color: var(--ink); margin-bottom: 2px; }
.advisor-tab small { font-size: 12px; color: var(--ink-faint); font-family: "DM Mono", monospace; }
.advisor-tab:hover { background: rgba(255, 255, 255, .5); }
.advisor-tab.active {
  background: var(--paper);
  color: var(--sea-deep);
  box-shadow: inset 0 3px 0 var(--sea);
}
.advisor-tab.active b { color: var(--sea-deep); }
.advisor-result {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 32px;
  padding: 36px 40px;
  align-items: center;
  transition: opacity .15s ease;
}
.result-badge {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--sea-deep);
  background: var(--sea-wash);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 12px;
}
.advisor-result h3 {
  font-family: "Fraunces", Georgia, serif;
  font-size: 24px;
  color: var(--ink);
  margin-bottom: 12px;
  line-height: 1.3;
}
.advisor-result p {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 18px;
}
.advisor-specs {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.advisor-specs li {
  font-size: 13px;
  font-weight: 500;
  color: var(--ink);
  display: flex;
  align-items: center;
  gap: 8px;
}
.recommended-product-preview {
  background: var(--sand-wash);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  padding: 24px;
  text-align: center;
}
.rec-label {
  font-size: 11px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--sea-deep);
  letter-spacing: 1px;
  display: block;
  margin-bottom: 6px;
}
.recommended-product-preview h4 {
  font-size: 18px;
  color: var(--ink);
  margin-bottom: 6px;
}
.recommended-product-preview p {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 16px;
}

/* ============================================================
   Enhanced Storefront Reviews Breakdown & Filter Bar
   ============================================================ */
.reviews-summary-card {
  max-width: 980px;
  margin: 0 auto 36px;
  background: var(--paper);
  border: 1px solid var(--line-strong);
  border-radius: 20px;
  padding: 32px 36px;
  display: grid;
  grid-template-columns: 200px 1fr 220px;
  gap: 36px;
  align-items: center;
  box-shadow: var(--shadow-md);
}
.summary-score-box {
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  border-right: 1px solid var(--line);
  padding-right: 28px;
}
.big-score {
  font-family: "Fraunces", Georgia, serif;
  font-size: 54px;
  line-height: 1;
  color: var(--ink);
  font-weight: 700;
}
.stars-display {
  color: var(--sun);
  font-size: 20px;
  letter-spacing: 2px;
  margin: 6px 0 4px;
}
.summary-count {
  font-size: 12px;
  color: var(--ink-faint);
}
.summary-rec-badge {
  margin-top: 10px;
  font-size: 11.5px;
  font-weight: 700;
  color: var(--sea-deep);
  background: var(--sea-wash);
  padding: 4px 10px;
  border-radius: 999px;
}
.summary-bars {
  display: flex;
  flex-direction: column;
  gap: 7px;
}
.star-row {
  display: grid;
  grid-template-columns: 36px 1fr 28px;
  align-items: center;
  gap: 12px;
  font-size: 12px;
  color: var(--ink-soft);
  font-weight: 600;
}
.bar-bg {
  height: 8px;
  background: var(--sand);
  border-radius: 999px;
  overflow: hidden;
}
.bar-fill {
  height: 100%;
  background: var(--sun);
  border-radius: 999px;
  transition: width .4s ease;
}
.summary-cta-box {
  text-align: center;
  padding-left: 28px;
  border-left: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
.summary-cta-box p {
  font-size: 13px;
  color: var(--ink-soft);
  margin-bottom: 12px;
  text-align: center;
}
.summary-cta-box .btn {
  margin: 0 auto;
}
.summary-cta-box .review-login-hint {
  text-align: center;
}

.reviews-toolbar {
  max-width: 980px;
  margin: 0 auto 28px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.reviews-filter-pills {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}
.filter-pill {
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s ease;
}
.filter-pill:hover {
  border-color: var(--sea);
  background: var(--sea-wash);
}
.filter-pill.active {
  background: var(--sea-deep);
  color: #fff;
  border-color: var(--sea-deep);
}
.reviews-sort label {
  font-size: 12.5px;
  color: var(--ink-faint);
  display: flex;
  align-items: center;
  gap: 8px;
}
.reviews-sort select {
  padding: 6px 12px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--ink);
  font-size: 12.5px;
  font-weight: 600;
}

.review-badges-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}
.verified-badge {
  display: inline-flex;
  align-items: center;
  font-size: 11px;
  font-weight: 700;
  color: var(--sea-deep);
  background: var(--sea-wash);
  padding: 3px 8px;
  border-radius: 6px;
  letter-spacing: .2px;
}
.review-model-tag {
  font-size: 11px;
  color: var(--ink-soft);
  background: var(--sand);
  padding: 3px 8px;
  border-radius: 6px;
}
.review-helpful-btn {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 12px;
  color: var(--ink-soft);
  cursor: pointer;
  transition: all .2s ease;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.review-helpful-btn:hover {
  background: var(--sand-wash);
  border-color: var(--line-strong);
}
.review-helpful-btn.voted {
  background: var(--sea-wash);
  color: var(--sea-deep);
  border-color: var(--sea);
}

/* ============================================================
   Customer Account: Purifiers & Filter Health Hub
   ============================================================ */
.purifier-health-grid {
  display: grid;
  gap: 20px;
}
.purifier-health-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: all .2s ease;
}
.purifier-health-card:hover {
  box-shadow: var(--shadow-md);
  border-color: var(--line-strong);
}
.purifier-health-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
}
.purifier-badge-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.purifier-tag {
  font-size: 10.5px;
  font-weight: 800;
  letter-spacing: .5px;
  background: var(--sand);
  color: var(--ink);
  padding: 2px 8px;
  border-radius: 4px;
}
.purifier-title {
  font-size: 20px;
  font-weight: 700;
  color: var(--ink);
  margin-bottom: 2px;
}
.purifier-subtitle {
  font-size: 13px;
  color: var(--ink-faint);
}

.purifier-metrics {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 20px;
}
.metric-card {
  background: var(--sand-wash);
  border: 1px solid var(--line-faint);
  border-radius: 12px;
  padding: 16px;
}
.metric-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 8px;
}
.metric-head span {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink-soft);
}
.metric-head b {
  font-size: 16px;
  color: var(--ink);
}
.metric-bar-bg {
  height: 8px;
  background: var(--sand);
  border-radius: 999px;
  overflow: hidden;
  margin-bottom: 6px;
}
.metric-bar-fill {
  height: 100%;
  border-radius: 999px;
  transition: width .5s ease;
}
.metric-note {
  display: block;
  font-size: 11px;
  color: var(--ink-faint);
}
.tds-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--sea-deep);
  font-weight: 600;
  margin-bottom: 4px;
}
.tds-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--sea);
  box-shadow: 0 0 0 3px var(--sea-wash);
}
.service-due-note {
  font-size: 12px;
  color: var(--ink);
  font-weight: 600;
  margin-bottom: 4px;
}

.panel-title-tag {
  font: 700 10.5px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .08em;
  color: var(--sea);
  margin-bottom: 4px;
  text-transform: uppercase;
}

.purifier-serial-badge {
  font: 700 10.5px "SFMono-Regular", ui-monospace, monospace;
  background: var(--sand-wash);
  color: var(--ink-soft);
  padding: 3px 8px;
  border-radius: 4px;
  border: 1px solid var(--line);
}

.purifier-warranty-bar {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: var(--sea-wash);
  border-radius: 10px;
  color: var(--sea-deep);
  font-size: 13px;
  margin-bottom: 18px;
}
.purifier-warranty-bar.expired {
  background: var(--sand-wash);
  color: var(--ink-soft);
}

.purifier-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}
.btn-sm {
  padding: 8px 16px;
  font-size: 12.5px;
}

/* ============================================================
   Customer Account: Orders & Invoices List
   ============================================================ */
.account-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.order-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 22px 24px;
  box-shadow: var(--shadow-sm);
  transition: all .2s ease;
}
.order-card:hover {
  border-color: var(--line-strong);
  box-shadow: var(--shadow-md);
}
.order-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--line);
  margin-bottom: 14px;
}
.order-head b {
  font: 700 15px "SFMono-Regular", ui-monospace, monospace;
  color: var(--ink);
  display: block;
}
.order-head span:not(.status) {
  font-size: 12px;
  color: var(--ink-faint);
}
.order-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  font-size: 13.5px;
  color: var(--ink);
  border-bottom: 1px dashed var(--line-faint);
}
.order-item b {
  font-size: 12.5px;
  color: var(--ink-soft);
  margin: 0 12px;
}
.order-item em {
  font-style: normal;
  font-weight: 700;
  color: var(--ink);
}
.order-total {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0 6px;
  font-size: 14px;
  color: var(--ink-soft);
}
.order-total b {
  font-size: 16.5px;
  color: var(--sea-deep);
  font-weight: 800;
}
.order-address {
  margin: 8px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
  line-height: 1.4;
}
.order-actions-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 14px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
}
.order-actions-bar button {
  margin-left: auto;
}

/* ============================================================
   Service Request Stepper & Badges
   ============================================================ */
.request-type-badge {
  font-size: 11px;
  font-weight: 700;
  color: var(--sea-deep);
  background: var(--sea-wash);
  padding: 4px 10px;
  border-radius: 6px;
  letter-spacing: .02em;
}
.request-title-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.request-date-meta {
  display: block;
  margin-top: 4px;
  font-size: 11.5px;
  color: var(--ink-faint);
}

.request-stepper {
  display: flex;
  align-items: center;
  margin: 16px 0;
  padding: 12px 18px;
  background: var(--sand-wash);
  border: 1px solid var(--line);
  border-radius: 12px;
  gap: 12px;
}
.step-item {
  display: flex;
  align-items: center;
  gap: 8px;
  opacity: .45;
  transition: all .2s ease;
}
.step-item.active {
  opacity: 1;
}
.step-circle {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--sand);
  color: var(--ink);
  font-size: 11px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}
.step-item.active .step-circle {
  background: var(--sea);
  color: #fff;
  box-shadow: 0 2px 8px rgba(13, 148, 136, .3);
}
.step-label {
  font-size: 12px;
  font-weight: 700;
  color: var(--ink);
}
.step-line {
  flex: 1;
  height: 2px;
  background: var(--line);
}
.step-line.active {
  background: var(--sea);
}

.request-detail-box {
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 14px 16px;
  margin: 12px 0;
  font-size: 13.5px;
  line-height: 1.5;
}
.request-detail-box p { margin: 4px 0; }
.request-slot { color: var(--sea-deep); font-weight: 500; }
.request-address { color: var(--ink-soft); font-size: 12.5px; }

.request-notes-box {
  margin: 12px 0;
  padding: 12px 16px;
  background: var(--sand-wash);
  border: 1px dashed var(--line-strong);
  border-radius: 8px;
  font-size: 12.5px;
}
.request-notes-box b { color: var(--ink); display: block; margin-bottom: 6px; }
.notes-content { white-space: pre-wrap; color: var(--ink-soft); line-height: 1.5; }

/* Technician / Assigned Engineer Profile Card */
.technician-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-radius: 12px;
  margin: 14px 0;
  border: 1px solid var(--line);
  flex-wrap: wrap;
}
.technician-card.assigned {
  background: var(--sea-wash);
  border-color: rgba(13, 148, 136, .35);
}
.technician-card.unassigned {
  background: var(--sand-wash);
}
.technician-avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--sea);
  color: #fff;
  font-size: 18px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.technician-avatar.fallback {
  background: var(--sun);
  color: var(--sun-ink);
}
.technician-info { flex: 1; min-width: 200px; }
.technician-tag {
  font: 700 10px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .08em;
  color: var(--sea-deep);
  margin-bottom: 2px;
}
.technician-name {
  font-size: 15px;
  font-weight: 700;
  color: var(--ink);
  margin: 0;
}
.technician-role {
  font-size: 12px;
  color: var(--ink-soft);
  margin: 2px 0 0;
}
.technician-assigned-time {
  display: block;
  font-size: 11px;
  color: var(--ink-faint);
  margin-top: 4px;
}
.technician-actions {
  display: flex;
  gap: 8px;
}
.technician-call-btn {
  background: var(--sea-deep) !important;
  color: #fff !important;
  font-weight: 700;
}

.request-user-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  flex-wrap: wrap;
}

/* ============================================================
   Purifier Service History Modal
   ============================================================ */
.purifier-history-container {
  padding: 28px;
}
.purifier-history-timeline {
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin-top: 16px;
}
.history-item {
  display: flex;
  gap: 14px;
  padding: 14px 16px;
  background: var(--paper-2);
  border: 1px solid var(--line);
  border-radius: 10px;
}
.history-item-icon {
  font-size: 20px;
  line-height: 1;
}
.history-item-content { flex: 1; }
.history-item-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}
.history-item-head b { font-size: 13.5px; color: var(--ink); }
.history-date { font-size: 12px; color: var(--ink-faint); }
.history-notes { font-size: 12.5px; color: var(--ink-soft); margin: 4px 0; }
.history-amount { font-size: 12px; font-weight: 600; color: var(--ink); }
.history-free { font-size: 11.5px; font-weight: 600; color: var(--sea-deep); background: var(--sea-wash); padding: 2px 6px; border-radius: 4px; }
.history-empty-state {
  text-align: center;
  padding: 36px 20px;
  color: var(--ink-soft);
}
.history-empty-state p { font-size: 15px; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.history-empty-state small { color: var(--ink-faint); font-size: 12.5px; }

/* ============================================================
   Printable Invoice Dialog & Print Styles
   ============================================================ */
#invoiceDialog {
  width: min(780px, calc(100vw - 32px));
  max-width: 780px;
  overflow-x: hidden;
}
.invoice-container {
  padding: 32px 36px;
  background: var(--card);
  color: var(--ink);
  width: 100%;
  max-width: 100%;
  margin: 0 auto;
  box-sizing: border-box;
  overflow-x: hidden;
}
.invoice-content {
  width: 100%;
  box-sizing: border-box;
}
.invoice-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding-bottom: 20px;
  border-bottom: 2px solid var(--line);
}
.invoice-logo {
  font-family: "Fraunces", Georgia, serif;
  font-size: 28px;
  font-weight: 700;
  line-height: 1;
  color: var(--ink);
}
.invoice-logo span { color: var(--sea); }
.invoice-tag {
  font-size: 12px;
  font-weight: 600;
  color: var(--sea-deep);
  margin: 4px 0 2px;
}
.invoice-company-sub {
  font-size: 11px;
  color: var(--ink-faint);
  margin: 0;
}

.invoice-meta-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin: 22px 0;
  padding-bottom: 18px;
  border-bottom: 1px solid var(--line);
}
.invoice-col-title {
  display: block;
  font: 700 10.5px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .08em;
  color: var(--ink-faint);
  margin-bottom: 4px;
}
.invoice-customer-name {
  font-size: 16px;
  color: var(--ink);
}
.invoice-meta-line {
  margin: 3px 0 0;
  font-size: 12.5px;
  color: var(--ink-soft);
}
.invoice-number {
  font: 700 16px "SFMono-Regular", ui-monospace, monospace;
  color: var(--sea-deep);
}
.invoice-status-wrap {
  margin-top: 8px;
}
.status-paid {
  background: var(--sea-wash) !important;
  color: var(--sea-deep) !important;
  font-weight: 700;
  border: 1px solid rgba(13, 148, 136, .3);
}

.invoice-table {
  width: 100%;
  border-collapse: collapse;
  margin: 20px 0;
  table-layout: fixed;
  box-sizing: border-box;
}
.invoice-table th {
  padding: 10px 8px;
  font: 700 11px "SFMono-Regular", ui-monospace, monospace;
  letter-spacing: .04em;
  color: var(--ink-faint);
  border-bottom: 2px solid var(--line);
}
.invoice-table th:nth-child(1),
.invoice-table td:nth-child(1) {
  width: 50%;
  text-align: left;
  padding-left: 0;
}
.invoice-table th:nth-child(2),
.invoice-table td:nth-child(2) {
  width: 12%;
  text-align: center;
}
.invoice-table th:nth-child(3),
.invoice-table td:nth-child(3) {
  width: 19%;
  text-align: right;
  white-space: nowrap;
}
.invoice-table th:nth-child(4),
.invoice-table td:nth-child(4) {
  width: 19%;
  text-align: right;
  padding-right: 0;
  white-space: nowrap;
}

/* 6-Column GST Tax Invoice Table */
.invoice-table.gst-table th {
  font-size: 10px;
  padding: 8px 4px;
}
.invoice-table.gst-table td {
  font-size: 12.5px;
  padding: 12px 4px;
}
.invoice-table.gst-table th:nth-child(1),
.invoice-table.gst-table td:nth-child(1) { width: 40%; text-align: left; padding-left: 0; }
.invoice-table.gst-table th:nth-child(2),
.invoice-table.gst-table td:nth-child(2) { width: 8%; text-align: center; }
.invoice-table.gst-table th:nth-child(3),
.invoice-table.gst-table td:nth-child(3) { width: 14%; text-align: right; white-space: nowrap; }
.invoice-table.gst-table th:nth-child(4),
.invoice-table.gst-table td:nth-child(4) { width: 12%; text-align: right; white-space: nowrap; }
.invoice-table.gst-table th:nth-child(5),
.invoice-table.gst-table td:nth-child(5) { width: 12%; text-align: right; white-space: nowrap; }
.invoice-table.gst-table th:nth-child(6),
.invoice-table.gst-table td:nth-child(6) { width: 14%; text-align: right; padding-right: 0; white-space: nowrap; }

.invoice-item-title-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
}
.invoice-hsn-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  font-family: "SFMono-Regular", ui-monospace, monospace;
  color: var(--sea-deep);
  background: var(--sea-wash);
  padding: 1px 6px;
  border-radius: 4px;
  line-height: 1.4;
}

.invoice-table td {
  padding: 14px 8px;
  border-bottom: 1px solid var(--line-faint);
  font-size: 13.5px;
  vertical-align: top;
}
.invoice-item-name {
  display: block;
  color: var(--ink);
  font-size: 14px;
  font-weight: 700;
  word-break: break-word;
}
.invoice-item-desc {
  margin: 4px 0 0;
  font-size: 11px;
  color: var(--ink-faint);
  line-height: 1.4;
  white-space: normal;
  word-break: break-word;
}
.text-right { text-align: right !important; }
.text-center { text-align: center !important; }

.invoice-summary-box {
  display: flex;
  justify-content: flex-end;
  margin: 16px 0 24px;
  width: 100%;
}
.invoice-summary-table {
  width: 320px;
  max-width: 100%;
}
.summary-line {
  display: flex;
  justify-content: space-between;
  padding: 5px 0;
  font-size: 13px;
  color: var(--ink-soft);
}
.summary-line.grand-total {
  border-top: 2px solid var(--line);
  padding-top: 8px;
  margin-top: 4px;
  font-size: 16px;
  font-weight: 800;
  color: var(--ink);
}
.free-badge {
  color: var(--sea-deep);
  font-weight: 700;
  font-size: 12px;
}

.invoice-assurance-badge {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 18px;
  background: var(--sea-wash);
  border-radius: 10px;
  margin: 20px 0;
}
.assurance-icon { font-size: 24px; flex-shrink: 0; }
.assurance-text {
  font-size: 12px;
  color: var(--sea-deep);
  line-height: 1.45;
}

.invoice-footer-meta {
  text-align: center;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}
.invoice-footer-meta p { font-size: 13px; font-weight: 600; color: var(--ink); margin: 0; }
.invoice-footer-meta small { font-size: 11px; color: var(--ink-faint); display: block; margin-top: 2px; }

.invoice-actions {
  margin-top: 24px;
  display: flex;
  gap: 12px;
  justify-content: flex-end;
}

@media (max-width: 640px) {
  #invoiceDialog {
    width: calc(100vw - 20px);
  }
  .invoice-container {
    padding: 22px 18px;
  }
  .invoice-meta-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .invoice-meta-col.text-right {
    text-align: left !important;
  }
  .invoice-table th:nth-child(1),
  .invoice-table td:nth-child(1) { width: 44%; }
  .invoice-table th:nth-child(2),
  .invoice-table td:nth-child(2) { width: 14%; }
  .invoice-table th:nth-child(3),
  .invoice-table td:nth-child(3) { width: 21%; }
  .invoice-table th:nth-child(4),
  .invoice-table td:nth-child(4) { width: 21%; }
  .invoice-summary-table {
    width: 100%;
  }
}

@media print {
  body * { visibility: hidden !important; }
  #invoiceDialog, #invoiceDialog * { visibility: visible !important; }
  #invoiceDialog {
    position: absolute !important;
    left: 0 !important;
    top: 0 !important;
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    border: 0 !important;
    background: #ffffff !important;
    color: #000000 !important;
    box-shadow: none !important;
  }
  .invoice-container {
    padding: 20px !important;
    background: #ffffff !important;
    color: #000000 !important;
    max-width: 100% !important;
  }
  .invoice-container * {
    color: #000000 !important;
    background-color: transparent !important;
  }
  .invoice-head, .invoice-meta-grid, .invoice-table th, .invoice-table td, .summary-line.grand-total {
    border-color: #cccccc !important;
  }
  .no-print { display: none !important; }
}

/* ============================================================
   Keyframes
   ============================================================ */
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 0%, 100% { transform: rotate(-45deg) translateY(0); } 50% { transform: rotate(-45deg) translateY(-3px); } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-14px); } }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: .35; } }
@keyframes drip {
  0% { opacity: 0; transform: translateY(0); }
  35% { opacity: 1; }
  80% { opacity: 1; transform: translateY(14px); }
  100% { opacity: 0; transform: translateY(20px); }
}
@keyframes fillUp { 0% { height: 22%; } 50% { height: 78%; } 100% { height: 22%; } }
@keyframes fillCup { 0% { height: 18%; } 50% { height: 82%; } 100% { height: 18%; } }
@keyframes waveShift { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
@keyframes scrollX { to { transform: translateX(-50%); } }
@keyframes dialogIn { from { opacity: 0; transform: translateY(16px) scale(.97); } to { opacity: 1; transform: none; } }
@keyframes cardIn { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ============================================================
   Responsive
   ============================================================ */
@media (max-width: 1024px) {
  .hero { grid-template-columns: 1fr; text-align: center; min-height: auto; padding-top: 130px; }
  .hero-copy { max-width: 640px; margin: 0 auto; }
  .hero-text { margin-left: auto; margin-right: auto; }
  .hero-actions, .trust-row, .section-head.center .eyebrow { justify-content: center; }
  .eyebrow { justify-content: center; }
  .hero-visual { min-height: 480px; margin-top: 20px; }
  .product-detail .detail-copy { padding: 16px 24px 28px; }
  .advisor-result { grid-template-columns: 1fr; }
  .reviews-summary-card { grid-template-columns: 1fr; gap: 24px; }
  .summary-score-box, .summary-cta-box { border: 0; padding: 0; }
  .purifier-metrics { grid-template-columns: 1fr; }
}

@media (max-width: 760px) {
  .site-header { padding: 14px 20px; }
  .site-header.scrolled { padding: 10px 20px; }
  .site-nav { display: none; }
  .header-phone { display: none; }
  .hero { padding: 120px 20px 60px; }
  .hero h1 { font-size: clamp(38px, 10vw, 56px); }
  .trust-row { gap: 22px; }
  .hero-visual { min-height: 400px; }
  .chip-c { display: none; }
  .section { padding: 60px 20px; }
  .marquee span { font-size: 11px; gap: 28px; }
  .dashboard { padding: 24px 16px 60px; }
  .dash-brand { display: none; }
  .panel-head { flex-direction: column; align-items: flex-start; }
  .filters { width: 100%; }
  .search { flex: 1; }
  .search input { width: 100%; }
  .form-grid { grid-template-columns: 1fr; }
  .wide { grid-column: span 1; }
  .detail-grid { grid-template-columns: 1fr; }
  .detail-grid .wide-detail { grid-column: span 1; }
  .login-logo { margin-bottom: 20px; }
  .login-card { padding: 32px 24px; }
  .advisor-sources { grid-template-columns: 1fr; }
  .advisor-tab { border-right: 0; border-bottom: 1px solid var(--line); }
  .advisor-result { padding: 24px 20px; }
  .reviews-summary-card { padding: 24px 20px; }
  .request-stepper { flex-direction: column; align-items: flex-start; gap: 8px; }
  .step-line { display: none; }
  dialog form { padding: 22px; }
  dialog { width: calc(100vw - 24px); max-width: 100vw; }
  #clientDetailDialog .detail-copy { padding: 24px 20px 26px; }
  #clientDetailDialog .modal-heading { padding-right: 38px; }
  .detail-actions { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 18px; }
  .detail-actions .service-btn,
  .detail-actions .danger-btn {
    width: 100%;
    margin-left: 0;
    padding: 13px 12px;
    font-size: 12px;
    white-space: normal;
    display: flex;
    align-items: center;
    justify-content: center;
  }
  .product-detail .detail-copy { padding: 26px; }
}

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ============================================================
   Reviews Page (standalone /reviews.html)
   ============================================================ */
.reviews-page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.reviews-page .site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}
.reviews-page .site-nav a.active {
  color: var(--ocean);
  font-weight: 700;
}
.reviews-page-main {
  flex: 1;
}
.reviews-hero {
  padding: 64px 24px 32px;
  background: var(--sand-wash);
  border-bottom: 1px solid var(--line);
}
.reviews-hero h1 {
  font-family: "Fraunces", Georgia, serif;
  font-weight: 600;
  font-size: clamp(28px, 5vw, 44px);
  color: var(--ink);
  margin: 0 0 8px;
}
.reviews-hero p {
  max-width: 540px;
  margin: 0 auto;
  color: var(--ink-soft);
}
.reviews-summary-wrap {
  max-width: 960px;
  margin: -24px auto 0;
  padding: 0 24px;
  position: relative;
  z-index: 2;
}
.reviews-content-wrap {
  max-width: 960px;
  margin: 32px auto 48px;
  padding: 0 24px;
}
.reviews-results-count {
  text-align: center;
  margin: 20px 0 0;
  font-size: 12.5px;
  color: var(--ink-faint);
}

