/*
 * Allergy Buddy — order-form / product page styles.
 * Self-contained (tokens + components) so it matches the approved mockup
 * regardless of the global design-system.css. Loaded only on /product.
 */
:root {
	--bg: #F8F6F1; --bg-2: #EFEDE5; --paper: #FDFCFA;
	--ink: #14181D; --ink-2: #4D535D; --ink-3: #616770;
	--line: #E3DFD4; --line-2: #CFC9BB;
	--accent: #B9322A; --accent-deep: #7A1E18; --accent-soft: #F1DDD9;
	--red: #B9322A; --blue: #2A4A8A; --green: #3F7A44; --gold: #C98A2C;
	--sans: "DM Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
	--mono: "DM Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
}

.ab-of { font-family: var(--sans); color: var(--ink); }
.ab-of * { box-sizing: border-box; }

.ab-of .sec-head { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: end; margin-bottom: 28px; }
.ab-of .sec-head h2 { font-family: var(--sans); font-weight: 500; font-size: clamp(28px, 3.6vw, 42px); letter-spacing: -0.03em; line-height: 1.04; margin: 12px 0 0; }
.ab-of .sec-head p { margin: 0; font-size: 16px; color: var(--ink-2); max-width: 52ch; }
@media (max-width: 860px) { .ab-of .sec-head { grid-template-columns: 1fr; gap: 14px; } }

.ab-of .eyebrow { font-family: var(--mono); font-size: 11.5px; font-weight: 500; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-3); display: inline-flex; align-items: center; gap: 10px; }
.ab-of .eyebrow::before { content: ""; width: 18px; height: 2px; background: var(--accent); border-radius: 2px; }

.ab-of .btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; padding: 14px 22px; border-radius: 999px; font-family: var(--sans); font-size: 14.5px; font-weight: 500; line-height: 1; border: 1.5px solid transparent; cursor: pointer; text-decoration: none; transition: background-color .18s, color .18s, border-color .18s, transform .18s; }
.ab-of .btn:hover { transform: translateY(-1px); }
.ab-of .btn--cta { background: var(--accent); color: #fff; border-color: var(--accent); }
.ab-of .btn--cta:hover { background: var(--accent-deep); border-color: var(--accent-deep); }
.ab-of .btn--ghost { background: transparent; color: var(--ink); border-color: var(--line-2); }
.ab-of .btn--ghost:hover { border-color: var(--ink); }
.ab-of .btn--block { width: 100%; }
.ab-of .btn[aria-disabled="true"] { opacity: .5; pointer-events: none; }
.ab-of .btn .arr { transition: transform .18s; }
.ab-of .btn:hover .arr { transform: translateX(3px); }

.ab-of .qty { display: inline-flex; align-items: center; border: 1.5px solid var(--line-2); border-radius: 999px; overflow: hidden; }
.ab-of .qty button { width: 34px; height: 38px; border: 0; background: transparent; font-size: 17px; color: var(--ink); cursor: pointer; font-family: var(--sans); line-height: 1; }
.ab-of .qty button:hover { background: var(--bg-2); }
.ab-of .qty input { width: 40px; height: 38px; border: 0; text-align: center; font-family: var(--mono); font-size: 14px; background: transparent; color: var(--ink); -moz-appearance: textfield; }
.ab-of .qty input::-webkit-outer-spin-button, .ab-of .qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.ab-of .order-card { background: var(--paper); border: 1px solid var(--line); border-radius: 20px; overflow: hidden; }
.ab-of .of-head { display: grid; grid-template-columns: 1fr 110px 132px 96px; gap: 16px; padding: 16px 26px; background: var(--bg-2); border-bottom: 1px solid var(--line); font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--ink-3); }
.ab-of .of-head .ar { text-align: right; }
.ab-of .of-row { display: grid; grid-template-columns: 1fr 110px 132px 96px; gap: 16px; padding: 22px 26px; border-bottom: 1px solid var(--line); align-items: center; }
.ab-of .of-name { display: grid; grid-template-columns: 84px minmax(0, 1fr); gap: 16px; align-items: start; }
.ab-of .of-thumb { width: 84px; height: 84px; object-fit: contain; background: var(--bg); border: 1px solid var(--line); border-radius: 12px; display: block; }
.ab-of .of-name strong { display: block; font-size: 16px; font-weight: 600; letter-spacing: -0.015em; }
.ab-of .of-name .of-code { display: block; margin-top: 2px; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); }
.ab-of .of-name p { margin: 4px 0 0; font-size: 13px; color: var(--ink-2); max-width: 52ch; }
.ab-of .of-name .tag { display: inline-block; margin-top: 8px; font-family: var(--mono); font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--accent); }
.ab-of .of-price { font-family: var(--mono); font-size: 14px; color: var(--ink-2); text-align: right; }
.ab-of .of-price small { color: var(--ink-3); }
.ab-of .of-row .qty-cell { display: flex; justify-content: flex-end; }
.ab-of .of-line { font-family: var(--mono); font-size: 15px; font-weight: 500; text-align: right; }
.ab-of .of-foot { display: flex; justify-content: flex-end; padding: 26px; }
.ab-of .of-foot > div { width: min(100%, 340px); }
.ab-of .of-totals { display: flex; flex-direction: column; gap: 10px; }
.ab-of .of-totals .row { display: flex; justify-content: space-between; font-size: 14.5px; color: var(--ink-2); }
.ab-of .of-totals .row .v { font-family: var(--mono); color: var(--ink); }
.ab-of .of-totals .row.total { border-top: 1px solid var(--line-2); padding-top: 12px; margin-top: 4px; font-size: 18px; font-weight: 600; color: var(--ink); }
.ab-of .of-totals .row.total .v { font-weight: 600; font-size: 19px; }
.ab-of .of-ctas { display: flex; flex-direction: column; gap: 10px; margin-top: 16px; }
.ab-of .example-tag { display: inline-flex; align-items: center; gap: 7px; font-family: var(--mono); font-size: 10.5px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--ink-3); background: var(--bg-2); border: 1px dashed var(--line-2); border-radius: 999px; padding: 5px 11px; margin-bottom: 18px; }

@media (max-width: 720px) {
	.ab-of .of-head { display: none; }
	.ab-of .of-row { grid-template-columns: 1fr auto; gap: 10px 14px; }
	.ab-of .of-name { grid-column: 1 / -1; }
	.ab-of .of-price { text-align: left; }
	.ab-of .of-foot { justify-content: stretch; }
	.ab-of .of-foot > div { width: 100%; }
}
