/* Sandeep Machiraju — component classes. Colors, spacing and radii come from tokens.css; nothing here names a hex. */

.sm-panel { background: var(--surface); color: var(--text); font-family: var(--font-sans); font-size: 17px; line-height: 1.6; font-weight: 400; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; box-sizing: border-box; }
.sm-panel *, .sm-panel *::before, .sm-panel *::after { box-sizing: border-box; }

/* ---------- The name ---------- */
.sm-wordmark { font-family: var(--font-serif); font-weight: 370; font-variation-settings: 'opsz' 72; letter-spacing: -0.015em; line-height: 1.05; color: var(--clay); white-space: nowrap; font-size: 64px; text-decoration: none; }
.sm-credit { font-family: var(--font-serif); font-weight: 400; font-size: 16px; line-height: 1.3; letter-spacing: -0.005em; color: var(--text); white-space: nowrap; text-decoration: none; }
.sm-signoff { font-family: var(--font-serif); font-style: italic; font-weight: 400; font-size: 24px; line-height: 1.3; color: var(--text); white-space: nowrap; }
.sm-stamp { --s: 64px; display: inline-grid; place-items: center; flex: none; width: var(--s); height: var(--s); border-radius: var(--radius-pill); border: max(1.5px, calc(var(--s) * 0.035)) solid var(--text); color: var(--text); font-family: var(--font-sans); font-weight: 600; font-size: calc(var(--s) * 0.36); line-height: 1; letter-spacing: 0.02em; text-indent: 0.02em; }

/* ---------- Type roles ---------- */
.sm-title { font-family: var(--font-serif); font-weight: 380; font-variation-settings: 'opsz' 72; font-size: 56px; line-height: 1.08; letter-spacing: -0.015em; color: var(--text); margin: 0; text-wrap: balance; }
.sm-title em, .sm-h2 em { font-style: italic; }
.sm-h2 { font-family: var(--font-serif); font-weight: 400; font-variation-settings: 'opsz' 40; font-size: 32px; line-height: 1.2; letter-spacing: -0.01em; color: var(--text); margin: 0; }
.sm-h3 { font-family: var(--font-serif); font-weight: 400; font-variation-settings: 'opsz' 28; font-size: 24px; line-height: 1.3; letter-spacing: -0.005em; color: var(--text); margin: 0; }
.sm-deck { font-family: var(--font-sans); font-size: 20px; line-height: 1.5; color: var(--text-body); margin: 0; }
.sm-body { font-family: var(--font-sans); font-size: 17px; line-height: 1.6; color: var(--text); margin: 0; hyphens: manual; text-align: left; }
.sm-body-small { font-family: var(--font-sans); font-size: 15px; line-height: 1.5; color: var(--text-body); margin: 0; }
.sm-caption { font-family: var(--font-sans); font-size: 14px; line-height: 1.45; color: var(--text-muted); margin: 0; }
.sm-overline { font-family: var(--font-mono); font-weight: 500; font-size: 12px; line-height: 1.3; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin: 0; }
.sm-overline-tick::before { content: ""; display: inline-block; width: 24px; height: 2px; background: var(--clay); vertical-align: middle; margin: 0 12px 2px 0; }
.sm-mono { font-family: var(--font-mono); font-size: 13px; line-height: 1.5; letter-spacing: 0.02em; color: var(--text-muted); margin: 0; }
.sm-prose ol { margin: 0; padding-left: 1.4em; }
.sm-prose ol li { padding-left: 8px; }
.sm-prose ol li + li { margin-top: 8px; }
.sm-prose ol li::marker { font-family: var(--font-mono); font-size: 13px; color: var(--text-muted); }

/* ---------- Links and buttons ---------- */
.sm-link { color: var(--text); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: var(--text-muted); transition: text-decoration-color 150ms ease-out; }
.sm-link:hover { text-decoration-color: var(--text); }
.sm-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; height: 40px; padding: 0 16px; border-radius: var(--radius-button); border: 1px solid transparent; font-family: var(--font-sans); font-weight: 500; font-size: 15px; line-height: 1; white-space: nowrap; text-decoration: none; cursor: pointer; transition: background-color 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out; }
.sm-btn-primary { background: var(--action); color: var(--action-label); }
.sm-btn-primary:hover, .sm-btn-primary.is-hover { background: var(--action-hover); }
.sm-btn-ghost, .sm-btn-outline { background: transparent; border-color: var(--text-muted); color: var(--text); }
.sm-btn-ghost:hover, .sm-btn-ghost.is-hover, .sm-btn-outline:hover { background: var(--surface-recessed); border-color: var(--text); }
.sm-btn-sm { height: 32px; padding: 0 12px; font-size: 14px; }
.sm-btn-quiet { background: transparent; color: var(--text-muted); padding: 0 8px; }
.sm-btn-quiet:hover, .sm-btn-quiet.is-hover { background: var(--surface-recessed); color: var(--text); }
.sm-btn[disabled], .sm-btn.is-disabled { opacity: 0.45; cursor: not-allowed; }
.sm-btn:focus-visible, .sm-link:focus-visible, .sm-field:focus-visible, .sm-btn.is-focus { outline: 2px solid var(--focus); outline-offset: 2px; }
.sm-btn .sm-icon { width: 16px; height: 16px; }
.sm-icon { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: butt; stroke-linejoin: miter; }

/* ---------- Tags, cards, rules ---------- */
.sm-tag { display: inline-flex; align-items: center; height: 24px; padding: 0 10px; border: 1px solid var(--rule-strong); border-radius: var(--radius-pill); font-family: var(--font-mono); font-weight: 500; font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-muted); white-space: nowrap; }
.sm-card { display: block; border: 1px solid var(--rule); border-radius: var(--radius-panel); padding: 24px; background: var(--surface); color: var(--text); text-decoration: none; transition: background-color 150ms ease-out; }
a.sm-card:hover, .sm-card.is-hover { background: var(--surface-recessed); }
.sm-rule { border: 0; border-top: 1px solid var(--rule); margin: 0; }
.sm-rule-strong { border: 0; border-top: 1px solid var(--rule-strong); margin: 0; }
.sm-rule-clay { border: 0; width: 48px; height: 2px; background: var(--clay); margin: 0; }

/* ---------- Editorial blocks ---------- */
.sm-quote { margin: 0; padding: 0; }
.sm-quote::before { content: ""; display: block; width: 48px; height: 2px; background: var(--clay); margin-bottom: 20px; }
.sm-quote p { font-family: var(--font-serif); font-style: italic; font-weight: 380; font-variation-settings: 'opsz' 36; font-size: 28px; line-height: 1.35; color: var(--text); margin: 0; text-wrap: balance; }
.sm-quote footer { margin-top: 16px; font-family: var(--font-mono); font-size: 13px; letter-spacing: 0.02em; color: var(--text-muted); }
.sm-code-inline { font-family: var(--font-mono); font-size: 0.88em; background: var(--surface-sunk); color: var(--text); padding: 0.1em 0.35em; border-radius: var(--radius-inline); }
.sm-code { margin: 0; background: var(--surface-sunk); color: var(--text); border-radius: var(--radius-panel); padding: 20px 24px; font-family: var(--font-mono); font-size: 14px; line-height: 1.6; overflow: auto; tab-size: 2; white-space: pre; }
.sm-code .c { color: var(--text-muted); font-style: italic; }
.sm-code .k { font-weight: 500; }
.sm-code .s { color: var(--text-muted); }
.sm-figure { margin: 0; }
.sm-figure .sm-figure-frame { border: 1px solid var(--rule); border-radius: var(--radius-panel); background: var(--surface); overflow: hidden; }
.sm-figure figcaption { margin-top: 12px; font-family: var(--font-mono); font-size: 13px; line-height: 1.5; letter-spacing: 0.02em; color: var(--text-muted); }
.sm-table { width: 100%; border-collapse: collapse; font-family: var(--font-sans); font-size: 15px; line-height: 1.5; color: var(--text); font-variant-numeric: tabular-nums; }
.sm-table th { text-align: left; font-family: var(--font-mono); font-weight: 500; font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); padding: 0 16px 10px 0; border-bottom: 1px solid var(--rule-strong); }
.sm-table td { padding: 12px 16px 12px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.sm-table .num { text-align: right; padding-right: 0; font-family: var(--font-mono); font-size: 14px; }

/* ---------- Forms ---------- */
.sm-field { height: 40px; min-width: 0; padding: 0 12px; border: 1px solid var(--rule-strong); border-radius: var(--radius-button); background: var(--surface); color: var(--text); font-family: var(--font-sans); font-size: 16px; transition: border-color 150ms ease-out; }
.sm-field::placeholder { color: var(--text-muted); opacity: 1; }
.sm-field:hover, .sm-field:focus { border-color: var(--text); }
.sm-signup { display: flex; gap: 8px; max-width: 440px; }
.sm-signup .sm-field { flex: 1; }

/* ---------- Page furniture ---------- */
.sm-masthead { display: flex; align-items: baseline; justify-content: space-between; gap: 32px; padding: 24px 0; border-bottom: 1px solid var(--rule); }
.sm-masthead .sm-wordmark { font-size: 40px; }
.sm-nav { display: flex; gap: 28px; font-family: var(--font-sans); font-weight: 500; font-size: 15px; }
.sm-nav a { color: var(--text-muted); text-decoration: none; transition: color 150ms ease-out; }
.sm-nav a:hover, .sm-nav a[aria-current] { color: var(--text); }
.sm-footer { display: flex; align-items: baseline; justify-content: space-between; gap: 32px; padding: 24px 0; border-top: 1px solid var(--rule); }
.sm-footer .sm-nav { font-weight: 400; font-size: 14px; gap: 24px; }
.sm-continue { display: inline-flex; align-items: center; gap: 8px; font-family: var(--font-sans); font-weight: 500; font-size: 15px; color: var(--text); text-decoration: none; }
.sm-continue .sm-icon { transition: transform 200ms ease-out; }
.sm-continue:hover .sm-icon { transform: translateX(4px); }
.sm-pager { display: flex; align-items: center; justify-content: space-between; padding: 20px 0; border-top: 1px solid var(--rule); }
.sm-list { list-style: none; margin: 0; padding: 0; }
.sm-list li { display: grid; grid-template-columns: 120px 1fr; gap: 24px; align-items: baseline; padding: 16px 0; border-top: 1px solid var(--rule); }
.sm-list li:last-child { border-bottom: 1px solid var(--rule); }
.sm-list a { font-family: var(--font-serif); font-weight: 400; font-size: 20px; line-height: 1.3; letter-spacing: -0.005em; color: var(--text); text-decoration: none; }
.sm-list a:hover { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 4px; }

/* ---------- Long-form spacing (last, so it wins over each block's own margin reset) ---------- */
.sm-prose > * + * { margin-top: 24px; }
.sm-prose > h2:not(:first-child), .sm-prose > h3:not(:first-child) { margin-top: 40px; }
.sm-prose > h2 + *, .sm-prose > h3 + * { margin-top: 12px; }
.sm-prose > blockquote { margin-top: 36px; margin-bottom: 36px; }

@media (prefers-reduced-motion: reduce) { .sm-panel * { transition: none !important; } }
