/* Xarah – site styles
   Colours follow the product: green is fine, amber is due soon, red needs action. */

:root {
	--paper: #fbfaf7;
	--surface: #ffffff;
	--tint: #f3f1ec;
	--ink: #15222c;
	--ink-soft: #4a5863;
	--ink-faint: #7b8791;
	--line: #e3e0d9;

	--red: #d81e2a;
	--red-dark: #b3141f;
	--red-tint: #fdeceb;
	--green: #12804a;
	--green-tint: #e6f4eb;
	--amber: #b97a06;
	--amber-tint: #fdf3dc;

	--radius: 14px;
	--radius-small: 8px;
	--shadow: 0 1px 2px rgba(21, 34, 44, .06), 0 12px 32px -12px rgba(21, 34, 44, .18);
	--shadow-big: 0 2px 4px rgba(21, 34, 44, .06), 0 32px 64px -24px rgba(21, 34, 44, .32);

	--font: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
	--wrap: 1120px;
	--gutter: 24px;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
	margin: 0;
	background: var(--paper);
	color: var(--ink);
	font-family: var(--font);
	font-size: 1.0625rem;
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
}

img, svg, iframe { max-width: 100%; }
img { height: auto; display: block; }

h1, h2, h3 {
	margin: 0 0 .5em;
	line-height: 1.1;
	letter-spacing: -.025em;
	text-wrap: balance;
}
h1 { font-size: clamp(2.5rem, 6.2vw, 4.5rem); font-weight: 800; letter-spacing: -.04em; line-height: 1; }
h2 { font-size: clamp(1.75rem, 3.4vw, 2.5rem); font-weight: 750; }
h3 { font-size: 1.25rem; font-weight: 700; letter-spacing: -.015em; }

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

a { color: var(--red-dark); text-underline-offset: .18em; }
a:hover { color: var(--red); }

:focus-visible { outline: 3px solid var(--ink); outline-offset: 3px; border-radius: 4px; }

.wrap {
	width: 100%;
	max-width: calc(var(--wrap) + 2 * var(--gutter));
	margin-inline: auto;
	padding-inline: var(--gutter);
}

.visually-hidden {
	position: absolute; width: 1px; height: 1px; overflow: hidden;
	clip: rect(0 0 0 0); white-space: nowrap;
}

.skip {
	position: absolute; left: var(--gutter); top: -4rem; z-index: 100;
	background: var(--ink); color: #fff; padding: .6rem 1rem; border-radius: var(--radius-small);
}
.skip:focus { top: .75rem; color: #fff; }

/* ---------- Buttons ---------- */

.btn {
	display: inline-flex; align-items: center; justify-content: center; gap: .5em;
	padding: .8em 1.4em;
	border: 2px solid var(--red); border-radius: 999px;
	background: var(--red); color: #fff;
	font: inherit; font-weight: 650; line-height: 1.2; text-decoration: none;
	transition: background .15s, border-color .15s, color .15s, transform .15s;
}
.btn:hover { background: var(--red-dark); border-color: var(--red-dark); color: #fff; transform: translateY(-1px); }
.btn--ghost { background: transparent; border-color: var(--ink); color: var(--ink); }
.btn--ghost:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn--small { padding: .5em 1.1em; font-size: .95rem; }
.btn--on-dark.btn--ghost { border-color: rgba(255, 255, 255, .6); color: #fff; }
.btn--on-dark.btn--ghost:hover { background: #fff; border-color: #fff; color: var(--ink); }

.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

/* ---------- Header ---------- */

.site-header {
	position: sticky; top: 0; z-index: 50;
	background: rgba(251, 250, 247, .88);
	backdrop-filter: saturate(1.4) blur(12px);
	-webkit-backdrop-filter: saturate(1.4) blur(12px);
	border-bottom: 1px solid var(--line);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 68px; gap: 1rem; }

.brand {
	display: inline-flex; align-items: center; gap: .45rem;
	color: var(--ink); text-decoration: none;
	font-size: 1.45rem; font-weight: 800; letter-spacing: -.04em;
}
.brand:hover { color: var(--ink); }
.brand img { width: 40px; height: 40px; }
.brand--light, .brand--light:hover { color: #fff; }

.site-nav ul { display: flex; align-items: center; gap: .25rem; margin: 0; padding: 0; list-style: none; }
.site-nav a:not(.btn) {
	display: block; padding: .5rem .8rem; border-radius: 999px;
	color: var(--ink-soft); font-weight: 550; font-size: .98rem; text-decoration: none;
}
.site-nav a:not(.btn):hover { color: var(--ink); background: var(--tint); }
.site-nav a[aria-current="page"]:not(.btn) { color: var(--ink); background: var(--tint); }
.site-nav .site-nav__lang { color: var(--ink-faint); }
.site-nav .btn { margin-left: .5rem; }

.nav-toggle {
	display: none; width: 44px; height: 44px; padding: 0;
	border: 1px solid var(--line); border-radius: 12px; background: var(--surface); cursor: pointer;
}
.nav-toggle__bars, .nav-toggle__bars::before, .nav-toggle__bars::after {
	display: block; width: 18px; height: 2px; margin-inline: auto; background: var(--ink); border-radius: 2px; content: "";
}
.nav-toggle__bars { position: relative; }
.nav-toggle__bars::before { position: absolute; top: -6px; left: 0; }
.nav-toggle__bars::after { position: absolute; top: 6px; left: 0; }

@media (max-width: 760px) {
	.nav-toggle { display: block; }
	.site-nav {
		display: none; position: absolute; left: 0; right: 0; top: 100%;
		background: var(--paper); border-bottom: 1px solid var(--line);
		padding: .5rem var(--gutter) 1.25rem;
	}
	.site-nav.is-open { display: block; }
	.site-nav ul { flex-direction: column; align-items: stretch; gap: 0; }
	.site-nav a:not(.btn) { padding: .85rem .25rem; border-radius: 0; border-bottom: 1px solid var(--line); font-size: 1.05rem; }
	.site-nav .btn { margin: 1rem 0 0; width: 100%; }
}

/* ---------- Sections ---------- */

.section { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.section--tint { background: var(--tint); }
.section--tight { padding-block: clamp(2.5rem, 5vw, 4rem); }

.eyebrow {
	margin: 0 0 1rem;
	color: var(--red-dark);
	font-size: .8rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
}
.lead { font-size: clamp(1.125rem, 1.6vw, 1.3rem); line-height: 1.5; color: var(--ink-soft); max-width: 40em; }
.section-head { max-width: 46rem; margin-bottom: clamp(2rem, 4vw, 3rem); }
.muted { color: var(--ink-soft); }
.small { font-size: .9rem; }

/* ---------- Hero ---------- */

.hero { position: relative; padding-block: clamp(3rem, 7vw, 6rem) 0; overflow: hidden; }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, .85fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.hero h1 em { font-style: normal; color: var(--red); }
.hero .lead { margin-top: 1.5rem; }

@media (max-width: 900px) {
	.hero__grid { grid-template-columns: 1fr; }
}

/* The pulse line under the hero */
.pulse { display: block; width: 100%; height: 72px; margin-top: clamp(2.5rem, 6vw, 4.5rem); color: var(--red); }
.pulse path { fill: none; stroke: currentColor; stroke-width: 2; vector-effect: non-scaling-stroke; stroke-linejoin: round; stroke-linecap: round; }
@media (prefers-reduced-motion: no-preference) {
	.pulse { animation: pulse-draw 2.2s .2s cubic-bezier(.6, 0, .2, 1) backwards; }
	@keyframes pulse-draw { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
}

/* Status card: what Xarah tells you */
.status-card {
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
	box-shadow: var(--shadow-big); overflow: hidden;
}
.status-card__head {
	display: flex; justify-content: space-between; align-items: baseline; gap: 1rem;
	padding: 1rem 1.25rem; border-bottom: 1px solid var(--line);
	font-weight: 700;
}
.status-card__head span { color: var(--ink-faint); font-size: .8rem; font-weight: 500; }
.status-list { margin: 0; padding: 0; list-style: none; }
.status-list li {
	display: grid; grid-template-columns: auto 1fr auto; gap: .9rem; align-items: center;
	padding: .95rem 1.25rem; border-bottom: 1px solid var(--line);
}
.status-list li:last-child { border-bottom: 0; }
.status-list strong { display: block; font-size: .98rem; line-height: 1.3; }
.status-list small { display: block; color: var(--ink-faint); font-size: .84rem; line-height: 1.35; }

.dot { width: 12px; height: 12px; border-radius: 50%; background: var(--ink-faint); flex: none; }
.dot--ok { background: var(--green); }
.dot--soon { background: #e9a514; }
.dot--act { background: var(--red); }

.chip {
	display: inline-block; padding: .2em .7em; border-radius: 999px;
	font-size: .78rem; font-weight: 650; white-space: nowrap;
}
.chip--ok { background: var(--green-tint); color: var(--green); }
.chip--soon { background: var(--amber-tint); color: var(--amber); }
.chip--act { background: var(--red-tint); color: var(--red-dark); }

/* ---------- Cards and grids ---------- */

.grid { display: grid; gap: 1.25rem; }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 900px) { .grid--3 { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .grid--2 { grid-template-columns: 1fr; } }

.card {
	display: flex; flex-direction: column;
	background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius);
	padding: clamp(1.25rem, 2.5vw, 1.75rem);
}
.card p { color: var(--ink-soft); }
.card__icon {
	display: grid; place-items: center; width: 48px; height: 48px; margin-bottom: 1.25rem;
	border-radius: 12px; background: var(--red-tint); color: var(--red);
}
.card__icon--green { background: var(--green-tint); color: var(--green); }
.card__icon--ink { background: var(--tint); color: var(--ink); }
.card__icon svg { width: 26px; height: 26px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.card__foot { margin-top: auto; padding-top: 1.25rem; }
.card--dark { background: var(--ink); border-color: var(--ink); color: #fff; }
.card--dark p { color: rgba(255, 255, 255, .75); }

/* Signal levels */
.levels { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); overflow: hidden; }
.level { padding: clamp(1.25rem, 2.5vw, 2rem); border-left: 1px solid var(--line); border-top: 6px solid var(--ink-faint); }
.level:first-child { border-left: 0; }
.level--ok { border-top-color: var(--green); }
.level--soon { border-top-color: #e9a514; }
.level--act { border-top-color: var(--red); }
.level h3 { margin-bottom: .4em; }
.level p { color: var(--ink-soft); }
@media (max-width: 760px) {
	.levels { grid-template-columns: 1fr; }
	.level { border-left: 0; }
}

/* ---------- Media: screenshots and video ---------- */

.frame {
	margin: 0; border: 1px solid var(--line); border-radius: var(--radius);
	background: var(--surface); box-shadow: var(--shadow-big); overflow: hidden;
}
.frame::before {
	content: ""; display: block; height: 30px; border-bottom: 1px solid var(--line);
	background:
		radial-gradient(circle at 18px 15px, #d9d5cc 5px, transparent 5.5px),
		radial-gradient(circle at 36px 15px, #d9d5cc 5px, transparent 5.5px),
		radial-gradient(circle at 54px 15px, #d9d5cc 5px, transparent 5.5px),
		var(--tint);
}
.frame img { width: 100%; }
.frame--plain { box-shadow: var(--shadow); }

figure { margin: 0; }
figcaption { margin-top: .75rem; color: var(--ink-soft); font-size: .92rem; }

.video { position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: var(--ink); box-shadow: var(--shadow); }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

/* Text beside media, alternating sides */
.split { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.split + .split { margin-top: clamp(3.5rem, 8vw, 6rem); }
.split--flip > :first-child { order: 2; }
.split--wide { grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); }
.split h2 span { color: var(--ink-faint); }
@media (max-width: 900px) {
	.split, .split--wide { grid-template-columns: 1fr; }
	.split--flip > :first-child { order: 0; }
}

.ticks { margin: 1.25rem 0 0; padding: 0; list-style: none; }
.ticks li { position: relative; padding-left: 1.9rem; margin-bottom: .6rem; color: var(--ink-soft); }
.ticks li::before {
	content: ""; position: absolute; left: 0; top: .32em; width: 1.15rem; height: 1.15rem; border-radius: 50%;
	background: var(--green-tint) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M4 8.4l2.6 2.6L12 5.6' fill='none' stroke='%2312804a' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 80% no-repeat;
}

/* ---------- Page intro (inner pages) ---------- */

.page-head { padding-block: clamp(3rem, 7vw, 5.5rem) clamp(1rem, 3vw, 2rem); }
.page-head h1 { font-size: clamp(2.25rem, 5vw, 3.75rem); max-width: 16em; }
.page-head .lead { margin-top: 1.25rem; }

/* ---------- Pricing ---------- */

.plan h3 { font-size: 1.4rem; }
.plan__price { margin: 1rem 0 0; font-size: 2rem; font-weight: 800; letter-spacing: -.03em; line-height: 1.1; color: var(--ink); }
.plan__price small { font-size: .95rem; font-weight: 500; letter-spacing: 0; color: var(--ink-faint); }
.card .plan__price { color: var(--ink); }
.card--dark .plan__price { color: #fff; }
.card--dark .plan__price small { color: rgba(255, 255, 255, .65); }

.table-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); }
table { width: 100%; min-width: 620px; border-collapse: collapse; font-size: .98rem; }
th, td { padding: .85rem 1rem; text-align: center; border-bottom: 1px solid var(--line); }
tr:last-child > * { border-bottom: 0; }
thead th { background: var(--tint); font-size: .9rem; font-weight: 700; }
tbody th { text-align: left; font-weight: 550; }
td { color: var(--ink-soft); font-variant-numeric: tabular-nums; }
td small { display: block; color: var(--ink-faint); font-size: .8rem; }
.yes, .no { display: inline-grid; place-items: center; width: 1.6rem; height: 1.6rem; border-radius: 50%; }
.yes { background: var(--green-tint); color: var(--green); }
.no { color: var(--ink-faint); }
.yes svg, .no svg { width: 1rem; height: 1rem; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.price td { color: var(--ink); font-weight: 650; }
.footnote { margin-top: 1rem; color: var(--ink-soft); font-size: .9rem; max-width: 50rem; }
.table-title { margin: clamp(2.5rem, 5vw, 3.5rem) 0 1rem; font-size: 1.4rem; }

/* ---------- Demo ---------- */

.login { margin: 1.25rem 0 0; display: grid; grid-template-columns: auto 1fr; gap: .4rem 1rem; font-size: .98rem; }
.login dt { color: var(--ink-faint); }
.login dd { margin: 0; font-weight: 600; overflow-wrap: anywhere; }
.login code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .95em; }

.gallery { display: grid; gap: clamp(2rem, 5vw, 3.5rem); }

/* ---------- Call to action ---------- */

.cta { background: var(--ink); color: #fff; }
.cta__inner { display: grid; grid-template-columns: 1fr auto; gap: 2rem; align-items: center; }
.cta h2 { margin-bottom: .3em; }
.cta p { color: rgba(255, 255, 255, .75); max-width: 36em; }
.cta .actions { margin-top: 0; }
@media (max-width: 900px) { .cta__inner { grid-template-columns: 1fr; } }

/* ---------- Contact ---------- */

.contact-mail { display: inline-block; margin-top: .5rem; font-size: clamp(1.35rem, 3.2vw, 2.1rem); font-weight: 750; letter-spacing: -.02em; overflow-wrap: anywhere; }

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: rgba(255, 255, 255, .75); font-size: .95rem; border-top: 1px solid rgba(255, 255, 255, .12); }
.site-footer a { color: rgba(255, 255, 255, .85); text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer :focus-visible { outline-color: #fff; }
.site-footer__inner { display: grid; grid-template-columns: 1.2fr 1fr; gap: 2.5rem; padding-block: 3.5rem 2.5rem; }
.site-footer__about p { margin-top: 1rem; max-width: 26em; }
.site-footer__small { font-size: .85rem; color: rgba(255, 255, 255, .55); }
.site-footer__nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.site-footer__nav ul { margin: 0; padding: 0; list-style: none; }
.site-footer__nav li { margin-bottom: .6rem; }
.site-footer__legal { padding-block: 1.25rem 2rem; border-top: 1px solid rgba(255, 255, 255, .12); font-size: .85rem; color: rgba(255, 255, 255, .55); }
@media (max-width: 760px) { .site-footer__inner { grid-template-columns: 1fr; } }
