:root {
  color-scheme: light;
  --ink: #3b2a20;
  --brown: #6f432b;
  --caramel: #9a652f;
  --copper: #b66f43;
  --cream: #fbf7f1;
  --paper: #fffdf9;
  --soft: #f4ecdf;
  --line: #e7d4bf;
  --muted: #796558;
  --white: #ffffff;
  --shadow: 0 24px 70px rgba(75, 47, 31, .10);
}

* { box-sizing: border-box; }
[hidden] { display: none !important; }

html { min-height: 100%; background: var(--cream); }

body {
  min-width: 320px;
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(circle at 10% 14%, rgba(231, 207, 178, .38), transparent 25rem),
    radial-gradient(circle at 88% 46%, rgba(194, 142, 101, .13), transparent 28rem),
    var(--cream);
  font-family: Inter, Manrope, "Segoe UI", Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
}

button, input { font: inherit; }
button { -webkit-tap-highlight-color: transparent; }

.page-shell { min-height: 100vh; display: flex; flex-direction: column; }

.site-header {
  width: min(1180px, calc(100% - 40px));
  min-height: 104px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(154, 101, 47, .2);
}

.brand { display: inline-flex; align-items: center; text-decoration: none; }
.brand img { width: 132px; height: auto; display: block; }

.header-label {
  color: var(--muted);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: .22em;
  text-transform: uppercase;
  text-decoration: none;
}
.header-label:hover { color: var(--caramel); }
.header-label:focus-visible { outline: 3px solid rgba(182, 111, 67, .22); outline-offset: 4px; }

.calculator {
  width: min(940px, calc(100% - 40px));
  margin: 0 auto;
  padding: 76px 0 86px;
}

.intro { max-width: 760px; margin: 0 auto 48px; text-align: center; }
.eyebrow { margin: 0 0 18px; color: var(--copper); font-size: 10px; font-weight: 750; letter-spacing: .23em; }

.intro h1 {
  margin: 0;
  color: var(--ink);
  font-family: "Cormorant Garamond", "Noto Serif", Georgia, serif;
  font-size: clamp(42px, 7vw, 72px);
  font-weight: 500;
  letter-spacing: -.04em;
  line-height: .98;
}

.intro h1 em { color: var(--caramel); font-weight: 400; }
.intro-copy { max-width: 520px; margin: 24px auto 0; color: var(--muted); font-size: 15px; line-height: 1.7; }

.workspace {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 24px;
  background: rgba(255, 253, 249, .94);
  box-shadow: var(--shadow);
  backdrop-filter: blur(10px);
}

.step-block { padding: 38px 42px 40px; }
.step-block + .step-block { border-top: 1px solid var(--line); }

.step-heading { display: flex; align-items: flex-start; gap: 18px; margin-bottom: 26px; }
.step-number { padding-top: 5px; color: var(--copper); font-size: 10px; font-weight: 800; letter-spacing: .12em; }
.step-heading h2 { margin: 0 0 5px; font-family: "Cormorant Garamond", Georgia, serif; font-size: 28px; font-weight: 500; line-height: 1; }
.step-heading p { margin: 0; color: var(--muted); font-size: 13px; }

.material-picker { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.material-card {
  position: relative;
  min-height: 112px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  color: var(--ink);
  background: var(--white);
  text-align: left;
  cursor: pointer;
  transition: border-color .2s ease, background .2s ease, transform .2s ease, box-shadow .2s ease;
}

.material-card:hover { transform: translateY(-2px); border-color: #cda77e; box-shadow: 0 10px 24px rgba(75, 47, 31, .07); }
.material-card:focus-visible, .choice-pill:focus-visible, .quantity-button:focus-visible, .copy-button:focus-visible, .preset-button:focus-visible, .reset-settings:focus-visible, input:focus-visible { outline: 3px solid rgba(182, 111, 67, .22); outline-offset: 2px; }
.material-card.is-active { border-color: var(--caramel); background: #fcf5ec; box-shadow: inset 0 0 0 1px var(--caramel); }

.material-icon {
  width: 54px;
  height: 54px;
  flex: 0 0 54px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: var(--caramel);
  background: var(--soft);
}

.material-icon svg { width: 31px; height: 31px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.material-copy { display: flex; flex-direction: column; gap: 5px; }
.material-copy strong { font-family: "Cormorant Garamond", Georgia, serif; font-size: 25px; font-weight: 600; }
.material-copy small { color: var(--muted); font-size: 11px; }

.material-check {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: transparent;
  font-size: 12px;
  background: var(--white);
}

.material-card.is-active .material-check { border-color: var(--caramel); color: var(--white); background: var(--caramel); }

.measurement-picker { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 25px; }
.measurement-picker.is-single .choice-pill[data-mode="frozen"] { display: none; }

.choice-pill {
  min-height: 43px;
  padding: 0 17px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--muted);
  background: var(--white);
  font-size: 12px;
  font-weight: 650;
  cursor: pointer;
}

.choice-pill svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.choice-pill.is-active { border-color: var(--caramel); color: var(--brown); background: var(--soft); }

.fields-grid { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(210px, .8fr); gap: 18px; }
.field { display: flex; flex-direction: column; gap: 9px; }
.field > span:first-child { font-size: 12px; font-weight: 750; }
.field small { min-height: 18px; color: var(--muted); font-size: 10px; line-height: 1.5; }

.input-wrap {
  height: 64px;
  display: flex;
  align-items: center;
  border: 1px solid #d8bda1;
  border-radius: 10px;
  background: var(--white);
  transition: border-color .2s, box-shadow .2s;
}

.input-wrap:focus-within { border-color: var(--caramel); box-shadow: 0 0 0 4px rgba(154, 101, 47, .09); }
.input-wrap input { min-width: 0; width: 100%; height: 100%; padding: 0 12px 0 18px; border: 0; outline: 0; color: var(--ink); background: transparent; font-size: 25px; font-weight: 650; }
.input-wrap input::placeholder { color: #baa897; font-weight: 450; }
.unit { padding-right: 18px; color: var(--caramel); font-family: Georgia, serif; font-size: 19px; font-style: italic; }

.quantity-control {
  height: 64px;
  display: grid;
  grid-template-columns: 48px 1fr 48px;
  border: 1px solid #d8bda1;
  border-radius: 10px;
  background: var(--white);
}

.quantity-control input { min-width: 0; width: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; text-align: center; font-size: 20px; font-weight: 700; appearance: textfield; }
.quantity-control input::-webkit-inner-spin-button { appearance: none; }
.quantity-button { border: 0; color: var(--caramel); background: transparent; font-size: 24px; cursor: pointer; }
.quantity-button:first-child { border-right: 1px solid var(--line); }
.quantity-button:last-child { border-left: 1px solid var(--line); }
.quantity-button:hover { background: var(--soft); }

.wax-recipe { margin-top: 28px; padding: 24px; border: 1px solid var(--line); border-radius: 14px; background: #fcf8f3; }
.wax-recipe-heading { margin-bottom: 18px; display: flex; align-items: flex-end; justify-content: space-between; gap: 18px; }
.mini-kicker { display: block; margin-bottom: 6px; color: var(--copper); font-size: 10px; font-weight: 800; letter-spacing: .17em; }
.wax-recipe-heading h3 { margin: 0; font-family: "Cormorant Garamond", Georgia, serif; font-size: 24px; font-weight: 600; line-height: 1.1; }
.saved-note { color: var(--muted); font-size: 12px; }

.fragrance-panel { padding: 20px; border: 1px solid #ead8c5; border-radius: 11px; background: var(--white); }
.fragrance-topline { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.fragrance-topline > div { display: flex; flex-direction: column; gap: 4px; }
.fragrance-topline strong, .reserve-toggle strong { font-size: 14px; }
.fragrance-topline small, .reserve-toggle small { color: var(--muted); font-size: 12px; line-height: 1.4; }
.fragrance-topline output { min-width: 65px; color: var(--caramel); font-family: "Cormorant Garamond", Georgia, serif; font-size: 29px; font-weight: 600; text-align: right; }

.fragrance-range { width: 100%; height: 24px; margin: 14px 0 10px; appearance: none; outline: 0; background: transparent; }
.fragrance-range::-webkit-slider-runnable-track { height: 5px; border-radius: 999px; background: linear-gradient(90deg, var(--caramel) var(--range-fill, 0%), #eadfD2 var(--range-fill, 0%)); }
.fragrance-range::-moz-range-track { height: 5px; border-radius: 999px; background: #eadfd2; }
.fragrance-range::-moz-range-progress { height: 5px; border-radius: 999px; background: var(--caramel); }
.fragrance-range::-webkit-slider-thumb { width: 20px; height: 20px; margin-top: -7px; appearance: none; border: 4px solid var(--white); border-radius: 50%; background: var(--caramel); box-shadow: 0 0 0 1px var(--caramel), 0 3px 8px rgba(75, 47, 31, .18); cursor: grab; }
.fragrance-range::-moz-range-thumb { width: 14px; height: 14px; border: 4px solid var(--white); border-radius: 50%; background: var(--caramel); box-shadow: 0 0 0 1px var(--caramel); cursor: grab; }
.fragrance-presets { display: flex; flex-wrap: wrap; gap: 8px; }
.preset-button { min-width: 58px; height: 34px; padding: 0 12px; border: 1px solid var(--line); border-radius: 999px; color: var(--muted); background: var(--white); font-size: 12px; font-weight: 700; cursor: pointer; }
.preset-button:hover { border-color: #cda77e; color: var(--brown); }
.preset-button.is-active { border-color: var(--caramel); color: var(--white); background: var(--caramel); }
.material-limit-note { margin: 12px 0 0; color: var(--muted); font-size: 12px; line-height: 1.45; }

.reserve-row { margin-top: 12px; padding: 16px 18px; display: flex; align-items: center; justify-content: space-between; gap: 20px; border: 1px solid #ead8c5; border-radius: 11px; background: var(--white); }
.reserve-toggle { min-width: 0; display: flex; align-items: center; gap: 12px; cursor: pointer; }
.reserve-toggle > input { position: absolute; opacity: 0; pointer-events: none; }
.reserve-toggle > span:last-child { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.switch { width: 42px; height: 24px; flex: 0 0 42px; padding: 3px; border-radius: 999px; background: #d9cfc5; transition: background .2s; }
.switch span { width: 18px; height: 18px; display: block; border-radius: 50%; background: var(--white); box-shadow: 0 1px 4px rgba(0,0,0,.18); transition: transform .2s; }
.reserve-toggle input:checked + .switch { background: var(--caramel); }
.reserve-toggle input:checked + .switch span { transform: translateX(18px); }
.reserve-toggle input:focus-visible + .switch { outline: 3px solid rgba(182, 111, 67, .22); outline-offset: 2px; }
.reserve-value { height: 44px; flex: 0 0 auto; display: flex; align-items: center; overflow: hidden; border: 1px solid var(--line); border-radius: 8px; background: var(--cream); }
.reserve-value:focus-within { border-color: var(--caramel); }
.reserve-value input { width: 55px; height: 100%; border: 0; outline: 0; color: var(--ink); background: transparent; text-align: center; font-weight: 750; }
.reserve-value span { padding-right: 12px; color: var(--muted); font-size: 12px; }
.reserve-value:has(input:disabled) { opacity: .48; }

.result-card { margin: 0 42px 32px; overflow: hidden; border-radius: 16px; color: #fff8ef; background: var(--ink); }

.result-empty { min-height: 142px; padding: 30px 34px; display: flex; align-items: center; gap: 18px; }
.result-empty-icon { width: 46px; height: 46px; flex: 0 0 46px; display: grid; place-items: center; border: 1px solid rgba(255, 248, 239, .25); border-radius: 50%; color: #d6a57f; font-size: 23px; }
.result-empty strong { font-family: "Cormorant Garamond", Georgia, serif; font-size: 22px; font-weight: 500; }
.result-empty p { margin: 6px 0 0; color: #d8c6b9; font-size: 12px; line-height: 1.55; }

.result-content { padding: 30px 34px 28px; }
.result-topline { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: #d6a57f; font-size: 9px; font-weight: 800; letter-spacing: .2em; }
.copy-button { padding: 7px 10px; display: inline-flex; align-items: center; gap: 6px; border: 1px solid rgba(255, 255, 255, .18); border-radius: 7px; color: #f3e5d9; background: transparent; font-size: 9px; letter-spacing: 0; cursor: pointer; }
.copy-button svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 1.7; }
.copy-button:hover { background: rgba(255, 255, 255, .08); }

.result-context { margin: 18px 0 22px; color: #d8c6b9; font-size: 13px; }
.result-lines { display: grid; gap: 1px; border-radius: 10px; overflow: hidden; background: rgba(255, 255, 255, .09); }

.result-line { min-height: 72px; padding: 14px 18px; display: flex; align-items: center; justify-content: space-between; gap: 18px; background: rgba(255, 255, 255, .045); }
.result-line-label { display: flex; align-items: center; gap: 12px; }
.result-line-icon { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; color: #e0b994; background: rgba(214, 165, 127, .13); }
.result-line-icon svg { width: 19px; height: 19px; fill: none; stroke: currentColor; stroke-width: 1.55; stroke-linecap: round; stroke-linejoin: round; }
.result-line-label span:last-child { display: flex; flex-direction: column; gap: 3px; }
.result-line-label b { color: #fff8ef; font-size: 13px; font-weight: 650; }
.result-line-label small { color: #bda99a; font-size: 9px; }
.result-line strong { white-space: nowrap; color: #fff8ef; font-family: "Cormorant Garamond", Georgia, serif; font-size: 31px; font-weight: 500; }
.result-line strong span { color: #d6a57f; font-size: 16px; font-style: italic; }

.result-total { margin-top: 15px; padding: 15px 18px; display: flex; align-items: center; justify-content: space-between; border: 1px solid rgba(214, 165, 127, .25); border-radius: 10px; background: rgba(214, 165, 127, .08); }
.result-total span { color: #d8c6b9; font-size: 11px; }
.result-total strong { color: #fff8ef; font-family: Georgia, serif; font-size: 22px; font-weight: 500; }
.result-tip { margin: 17px 0 0; padding-left: 16px; position: relative; color: #cdbdb1; font-size: 10px; line-height: 1.55; }
.result-tip::before { content: "i"; position: absolute; left: 0; top: 1px; width: 11px; height: 11px; display: grid; place-items: center; border: 1px solid #d6a57f; border-radius: 50%; color: #d6a57f; font-family: Georgia, serif; font-size: 8px; font-style: italic; }

.settings { margin: 0 42px 40px; border-top: 1px solid var(--line); }
.settings summary { padding: 22px 2px 0; display: flex; align-items: center; justify-content: space-between; gap: 14px; list-style: none; color: var(--muted); cursor: pointer; }
.settings summary::-webkit-details-marker { display: none; }
.settings summary > span { display: inline-flex; align-items: center; gap: 8px; font-size: 11px; font-weight: 700; }
.settings summary svg { width: 16px; height: 16px; fill: none; stroke: var(--caramel); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.settings summary small { font-size: 9px; }
.settings[open] summary { color: var(--ink); }

.settings-body { margin-top: 18px; padding: 20px; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; border: 1px solid var(--line); border-radius: 12px; background: var(--cream); }
.setting-field { display: flex; flex-direction: column; gap: 7px; }
.setting-field > span:first-child { color: var(--ink); font-size: 10px; font-weight: 750; }
.setting-field > input, .ratio-inputs input, .percent-input input { width: 100%; height: 42px; border: 1px solid #d8bda1; border-radius: 7px; outline: 0; color: var(--ink); background: var(--white); text-align: center; font-weight: 650; }
.setting-field small { color: var(--muted); font-size: 8px; line-height: 1.4; }
.ratio-inputs { display: grid; grid-template-columns: 1fr 16px 1fr; align-items: center; text-align: center; }
.percent-input { display: grid; grid-template-columns: 1fr 28px; align-items: center; border: 1px solid #d8bda1; border-radius: 7px; background: var(--white); }
.percent-input input { border: 0; }
.percent-input b { color: var(--caramel); font-size: 11px; }
.reset-settings { grid-column: 1 / -1; justify-self: start; padding: 0; border: 0; border-bottom: 1px solid currentColor; color: var(--caramel); background: transparent; font-size: 9px; cursor: pointer; }

footer { width: min(940px, calc(100% - 40px)); margin: auto auto 0; padding: 26px 0 32px; display: flex; justify-content: center; gap: 9px; color: #9c887a; font-size: 9px; letter-spacing: .08em; }
.footer-dot { color: var(--copper); }

.toast { position: fixed; z-index: 20; left: 50%; bottom: 24px; padding: 11px 16px; border-radius: 999px; color: var(--white); background: var(--brown); box-shadow: 0 8px 24px rgba(0, 0, 0, .18); font-size: 11px; opacity: 0; transform: translate(-50%, 18px); pointer-events: none; transition: opacity .2s, transform .2s; }
.toast.is-visible { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 700px) {
  .site-header { min-height: 84px; }
  .brand img { width: 112px; }
  .calculator { padding: 52px 0 58px; }
  .intro { margin-bottom: 34px; }
  .intro h1 { font-size: clamp(38px, 12vw, 54px); }
  .intro-copy { font-size: 13px; }
  .workspace { border-radius: 18px; }
  .step-block { padding: 30px 24px 32px; }
  .material-picker, .fields-grid { grid-template-columns: 1fr; }
  .material-card { min-height: 98px; }
  .field small { min-height: 0; }
  .result-card { margin: 0 24px 25px; }
  .result-content, .result-empty { padding: 25px 22px; }
  .settings { margin: 0 24px 30px; }
  .settings-body { grid-template-columns: 1fr; }
  .wax-recipe { padding: 20px; }
  footer { flex-wrap: wrap; }
}

@media (max-width: 440px) {
  .site-header, .calculator, footer { width: min(100% - 26px, 940px); }
  .header-label { font-size: 8px; }
  .calculator { padding-top: 40px; }
  .intro h1 { font-size: 39px; }
  .eyebrow { font-size: 8px; }
  .step-block { padding-inline: 18px; }
  .step-heading { gap: 12px; }
  .step-heading h2 { font-size: 25px; }
  .material-card { padding: 16px; }
  .material-icon { width: 48px; height: 48px; flex-basis: 48px; }
  .measurement-picker { display: grid; }
  .choice-pill { justify-content: center; }
  .result-card { margin-inline: 18px; }
  .result-empty { align-items: flex-start; }
  .result-line { padding-inline: 13px; }
  .result-line strong { font-size: 27px; }
  .result-line-label { gap: 8px; }
  .result-line-icon { display: none; }
  .settings { margin-inline: 18px; }
  .settings summary small { display: none; }
  .wax-recipe-heading { align-items: flex-start; }
  .saved-note { display: none; }
  .reserve-row { align-items: flex-start; flex-direction: column; }
  .reserve-value { margin-left: 54px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
.vani-language-switch{margin-left:auto;display:flex;align-items:center;gap:7px;font:600 11px/1 Inter,Manrope,sans-serif;letter-spacing:.12em;color:#b28a67}.vani-language-switch a{color:#8a6448;text-decoration:none;padding:7px 4px;border-bottom:1px solid transparent}.vani-language-switch a.active{color:#3b2a20;border-bottom-color:#b77855}.vani-language-switch span{opacity:.45}
