/* Cilantro design tokens and shared base. Used by the public site, demo, installer and owner CMS. */
@font-face { font-family: "Manrope"; src: url("../fonts/manrope-latin-wght-normal.woff2") format("woff2"); font-weight: 200 800; font-style: normal; font-display: swap; }
@font-face { font-family: "Inter"; src: url("../fonts/inter-latin-wght-normal.woff2") format("woff2"); font-weight: 100 900; font-style: normal; font-display: swap; }

:root {
  --forest: #153D2B;
  --forest-2: #1D4D37;
  --herb: #6B9560;
  --sage: #DCE8D5;
  --sage-2: #EEF4EA;
  --sage-3: #F6F9F4;
  --white: #FFFFFF;
  --charcoal: #202420;
  --ink: #202420;
  --ink-2: #4B544C;
  --ink-3: #6E776F;
  --line: rgba(21, 61, 43, 0.10);
  --line-2: rgba(21, 61, 43, 0.16);
  --danger: #A23B2A;
  --danger-bg: #FBEDEA;
  --warn: #8A6412;
  --warn-bg: #FBF3DF;
  --ok: #2F6B3F;
  --ok-bg: #E5F1E6;
  --info: #2B5B78;
  --info-bg: #E6F0F6;

  --font-head: "Manrope", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;

  --r-xs: 8px;
  --r-sm: 10px;
  --r-md: 12px;
  --r-card: 24px;
  --r-card-lg: 28px;
  --r-photo: 32px;
  --r-hero: 40px;
  --r-pill: 999px;

  --shadow-1: 0 1px 2px rgba(21, 33, 26, 0.04), 0 1px 1px rgba(21, 33, 26, 0.03);
  --shadow-2: 0 2px 6px rgba(21, 33, 26, 0.05), 0 12px 32px rgba(21, 33, 26, 0.06);
  --shadow-3: 0 4px 12px rgba(21, 33, 26, 0.06), 0 24px 60px rgba(21, 33, 26, 0.10);
  --glass: rgba(255, 255, 255, 0.72);
  --glass-sage: rgba(238, 244, 234, 0.70);
  --glass-border: rgba(255, 255, 255, 0.65);
  --blur: saturate(170%) blur(18px);

  --wrap: 1240px;
  --gutter: clamp(20px, 4vw, 40px);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --focus: 0 0 0 3px rgba(107, 149, 96, 0.45);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; text-size-adjust: 100%; scroll-behavior: smooth; }
body { margin: 0; background: var(--white); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
img, svg, video { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--forest); text-decoration-thickness: 1px; text-underline-offset: 3px; }
a:hover { color: var(--herb); }
h1, h2, h3, h4 { font-family: var(--font-head); color: var(--charcoal); line-height: 1.12; letter-spacing: -0.022em; margin: 0 0 0.5em; font-weight: 700; }
h1 { font-size: clamp(2.4rem, 5.2vw, 4.4rem); letter-spacing: -0.035em; }
h2 { font-size: clamp(1.9rem, 3.6vw, 3rem); letter-spacing: -0.03em; }
h3 { font-size: 1.25rem; letter-spacing: -0.015em; }
p { margin: 0 0 1em; }
.tabular, .num, td.num, th.num { font-variant-numeric: tabular-nums; font-feature-settings: "tnum" 1; }
.muted { color: var(--ink-3); }
.small { font-size: 0.875rem; }
.xs { font-size: 0.78rem; }
.center { text-align: center; }
.nowrap { white-space: nowrap; }
.sr-only { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.skip-link { position: absolute; left: 16px; top: -60px; z-index: 1000; background: var(--forest); color: #fff; padding: 10px 16px; border-radius: var(--r-sm); }
.skip-link:focus { top: 12px; }
:focus-visible { outline: none; box-shadow: var(--focus); border-radius: 6px; }
.ic { flex: none; stroke-width: 1.75; }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 44px; padding: 10px 22px; border-radius: var(--r-pill); border: 1px solid transparent; font: 600 0.95rem/1 var(--font-body); text-decoration: none; cursor: pointer; transition: background 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease), transform 0.2s var(--ease), box-shadow 0.2s var(--ease); white-space: nowrap; }
.btn:hover { transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn-primary { background: var(--forest); color: #fff; box-shadow: 0 6px 18px rgba(21, 61, 43, 0.18); }
.btn-primary:hover { background: var(--forest-2); color: #fff; }
.btn-secondary { background: #fff; color: var(--forest); border-color: var(--line-2); }
.btn-secondary:hover { border-color: var(--herb); color: var(--forest); }
.btn-sage { background: var(--sage); color: var(--forest); }
.btn-sage:hover { background: #cfe0c6; color: var(--forest); }
.btn-ghost { background: transparent; color: var(--forest); }
.btn-ghost:hover { background: var(--sage-2); color: var(--forest); }
.btn-danger { background: #fff; color: var(--danger); border-color: rgba(162, 59, 42, 0.3); }
.btn-danger:hover { background: var(--danger-bg); color: var(--danger); }
.btn-sm { min-height: 34px; padding: 7px 14px; font-size: 0.85rem; }
.btn-xs { min-height: 28px; padding: 5px 10px; font-size: 0.78rem; }
.btn-lg { min-height: 54px; padding: 14px 28px; font-size: 1rem; }
.btn[disabled], .btn.is-disabled { opacity: 0.5; pointer-events: none; }
.btn-icon { width: 40px; height: 40px; min-height: 40px; padding: 0; border-radius: var(--r-sm); }

/* Forms */
.field { display: grid; gap: 6px; margin-bottom: 16px; }
.field > label, .label { font-weight: 600; font-size: 0.875rem; color: var(--charcoal); }
.hint { font-size: 0.8rem; color: var(--ink-3); }
.input, .select, .textarea, input[type=text].input, input[type=email].input {
  width: 100%; min-height: 44px; padding: 10px 14px; border: 1px solid var(--line-2); border-radius: var(--r-md); background: #fff;
  font: 400 0.95rem/1.4 var(--font-body); color: var(--ink); transition: border-color 0.15s, box-shadow 0.15s;
}
.textarea { min-height: 120px; resize: vertical; }
.input:focus, .select:focus, .textarea:focus { outline: none; border-color: var(--herb); box-shadow: var(--focus); }
.input[aria-invalid=true] { border-color: var(--danger); }
.select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23153D2B' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 38px; }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.92rem; }
.check input { width: 18px; height: 18px; accent-color: var(--forest); margin-top: 3px; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 18px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Alerts and pills */
.alert { padding: 14px 18px; border-radius: var(--r-md); border: 1px solid; font-size: 0.92rem; margin-bottom: 16px; display: flex; gap: 10px; align-items: flex-start; }
.alert-ok { background: var(--ok-bg); border-color: rgba(47, 107, 63, 0.2); color: var(--ok); }
.alert-error { background: var(--danger-bg); border-color: rgba(162, 59, 42, 0.2); color: var(--danger); }
.alert-warn { background: var(--warn-bg); border-color: rgba(138, 100, 18, 0.2); color: var(--warn); }
.alert-info { background: var(--info-bg); border-color: rgba(43, 91, 120, 0.2); color: var(--info); }
.pill { display: inline-flex; align-items: center; gap: 6px; padding: 3px 10px; border-radius: var(--r-pill); font-size: 0.75rem; font-weight: 600; line-height: 1.5; background: var(--sage-2); color: var(--forest); white-space: nowrap; }
.pill-ok { background: var(--ok-bg); color: var(--ok); }
.pill-warn { background: var(--warn-bg); color: var(--warn); }
.pill-danger { background: var(--danger-bg); color: var(--danger); }
.pill-info { background: var(--info-bg); color: var(--info); }
.pill-muted { background: #F1F3F1; color: var(--ink-3); }
.dot { width: 8px; height: 8px; border-radius: 50%; background: currentColor; display: inline-block; }

/* Glass, with opaque fallback */
.glass { background: rgba(255, 255, 255, 0.96); border: 1px solid var(--line); }
@supports ((-webkit-backdrop-filter: blur(1px)) or (backdrop-filter: blur(1px))) {
  .glass { background: var(--glass); -webkit-backdrop-filter: var(--blur); backdrop-filter: var(--blur); border-color: var(--glass-border); }
  .glass-sage { background: var(--glass-sage); }
}

/* Wordmark */
.wordmark { font-family: var(--font-head); font-weight: 700; letter-spacing: -0.04em; color: var(--forest); text-decoration: none; display: inline-flex; align-items: center; line-height: 1; }
.wordmark svg { height: 26px; width: auto; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; transition-duration: 0.001ms !important; scroll-behavior: auto !important; }
}

/* Responsive photographs from Creative Studio fill their rounded frames. */
picture { display: block; width: 100%; height: 100%; }
.ph-img { display: block; width: 100%; height: 100%; object-fit: cover; }
