/* SMSTunnel for Squarespace: the landing page, the settings page and the sign-in outcome pages. */
:root {
  --blue: #2240ae;
  --blue-dark: #182f86;
  --blue-soft: #eef1fb;
  --ink: #161b2e;
  --muted: #5b6275;
  --line: #e2e5ee;
  --bg: #f5f6fa;
  --card: #ffffff;
  --ok: #157347;
  --ok-soft: #e8f5ee;
  --warn: #8a5a00;
  --warn-soft: #fff5de;
  --bad: #b42318;
  --bad-soft: #fdecea;
  --radius: 14px;
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--ink);
  background: var(--bg);
  line-height: 1.5;
}
* { box-sizing: border-box; }
body { margin: 0; }
a { color: var(--blue); }
a:hover { color: var(--blue-dark); }
h1 { font-size: 1.6rem; line-height: 1.25; margin: 0 0 0.75rem; letter-spacing: -0.01em; }
h2 { font-size: 1.15rem; margin: 0; }
h3 { font-size: 1rem; margin: 0; }
p { margin: 0 0 0.75rem; }
code { font-family: ui-monospace, "SFMono-Regular", Consolas, monospace; background: var(--blue-soft); padding: 0.1rem 0.35rem; border-radius: 6px; }
[hidden] { display: none !important; }

main.narrow { max-width: 640px; margin: 0 auto; padding: 2rem 1rem 3rem; }
main.wide { max-width: 860px; margin: 0 auto; padding: 1.5rem 1rem 3rem; }
.center { text-align: center; }
.muted, .help { color: var(--muted); }
.help { font-size: 0.875rem; margin-top: 0.35rem; }

.brand { display: flex; align-items: center; gap: 0.6rem; font-weight: 700; font-size: 1.15rem; color: var(--ink); text-decoration: none; margin-bottom: 1.25rem; }
.brand small { font-weight: 500; color: var(--muted); }
.brand.small { margin: 0; font-size: 1rem; }
.brand img { border-radius: 8px; }

.topbar { background: var(--card); border-bottom: 1px solid var(--line); position: sticky; top: 0; z-index: 5; }
.topbar-inner { max-width: 860px; margin: 0 auto; padding: 0.7rem 1rem; display: flex; align-items: center; gap: 1rem; }
.site-name { flex: 1; color: var(--muted); font-size: 0.9rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; text-align: right; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.5rem; margin-bottom: 1.1rem; box-shadow: 0 1px 2px rgba(22, 27, 46, 0.04); }
.card-head { display: flex; align-items: center; gap: 0.65rem; margin-bottom: 0.9rem; }
.step { width: 1.7rem; height: 1.7rem; border-radius: 50%; background: var(--blue); color: #fff; font-weight: 700; font-size: 0.9rem; display: inline-flex; align-items: center; justify-content: center; flex: none; }
.hero .lead { font-size: 1.05rem; color: #2e3446; }
ol.steps { padding-left: 1.2rem; margin: 0.5rem 0 0; }
ol.steps li { margin-bottom: 0.6rem; }

label { display: block; font-weight: 600; font-size: 0.92rem; margin: 0.9rem 0 0.35rem; }
input[type="text"], input[type="tel"], input[type="password"], select, textarea {
  width: 100%; font: inherit; color: inherit; background: #fff; border: 1px solid #cfd4e2; border-radius: 10px; padding: 0.6rem 0.75rem;
}
textarea { resize: vertical; min-height: 3.2rem; }
input:focus, select:focus, textarea:focus, button:focus-visible, a:focus-visible { outline: 3px solid rgba(34, 64, 174, 0.25); outline-offset: 1px; border-color: var(--blue); }
.row { display: flex; gap: 0.6rem; }
.row input { flex: 1; min-width: 0; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1.2rem; }
@media (max-width: 640px) { .grid-2 { grid-template-columns: 1fr; } .row { flex-direction: column; } }

button, .button {
  font: inherit; font-weight: 600; border-radius: 10px; padding: 0.6rem 1.05rem; border: 1px solid #cfd4e2; background: #fff; color: var(--ink);
  cursor: pointer; text-decoration: none; display: inline-block; white-space: nowrap;
}
button:hover, .button:hover { border-color: var(--blue); color: var(--blue); }
button.primary, .button.primary { background: var(--blue); border-color: var(--blue); color: #fff; }
button.primary:hover, .button.primary:hover { background: var(--blue-dark); border-color: var(--blue-dark); color: #fff; }
button.link { background: none; border: none; padding: 0.25rem; color: var(--blue); font-weight: 600; }
button[disabled] { opacity: 0.6; cursor: progress; }

.field-error { color: var(--bad); font-size: 0.875rem; margin: 0.4rem 0 0; }
.status { font-size: 0.9rem; margin: 0.6rem 0 0; color: var(--ok); }
.status.bad { color: var(--bad); }
.key-saved { background: var(--ok-soft); border-radius: 10px; padding: 0.55rem 0.8rem; }
.phones { color: var(--muted); font-size: 0.9rem; }
details.hint { margin-top: 1rem; color: var(--muted); }
details.hint summary { cursor: pointer; color: var(--blue); font-weight: 600; }
details.hint ol { margin: 0.6rem 0 0; padding-left: 1.2rem; }

.banner { display: flex; gap: 1rem; align-items: center; justify-content: space-between; background: var(--warn-soft); border: 1px solid #f1d9a6; color: #5c3d00; border-radius: var(--radius); padding: 0.85rem 1.1rem; margin-bottom: 1.1rem; }
.banner p { margin: 0; }
.banner-actions { display: flex; gap: 0.5rem; align-items: center; flex: none; }

.text-row { border-top: 1px solid var(--line); padding: 1.1rem 0 0.4rem; }
.text-row:first-child { border-top: none; padding-top: 0.2rem; }
.text-head { display: flex; gap: 0.9rem; align-items: flex-start; margin-bottom: 0.6rem; }
.text-who { color: var(--muted); font-size: 0.875rem; margin: 0.1rem 0 0; }
.switch { position: relative; width: 2.6rem; height: 1.5rem; flex: none; margin: 0.1rem 0 0; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.slider { position: absolute; inset: 0; background: #cfd4e2; border-radius: 1rem; transition: background 0.15s; cursor: pointer; }
.slider::before { content: ""; position: absolute; width: 1.1rem; height: 1.1rem; left: 0.2rem; top: 0.2rem; background: #fff; border-radius: 50%; transition: transform 0.15s; box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2); }
.switch input:checked + .slider { background: var(--blue); }
.switch input:checked + .slider::before { transform: translateX(1.1rem); }
.switch input:focus-visible + .slider { outline: 3px solid rgba(34, 64, 174, 0.25); }
.text-row.off .template, .text-row.off .chips, .text-row.off .preview { opacity: 0.55; }
.chips { display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0.5rem 0; }
.chip { font-size: 0.8rem; font-weight: 600; padding: 0.2rem 0.55rem; border-radius: 999px; background: var(--blue-soft); color: var(--blue); border: 1px solid transparent; }
.chip:hover { border-color: var(--blue); }
.preview { background: #f3f5fa; border-radius: 10px; padding: 0.55rem 0.75rem; font-size: 0.92rem; }
.preview-label { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.06em; color: var(--muted); font-weight: 700; margin-right: 0.3rem; }
.parts { color: var(--muted); font-size: 0.8rem; white-space: nowrap; }

.savebar { display: flex; align-items: center; gap: 1rem; margin: -0.2rem 0 1.1rem; }
.savebar .status { margin: 0; }

.table-wrap { overflow-x: auto; }
table.activity { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
table.activity th { text-align: left; font-size: 0.78rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--muted); padding: 0.4rem 0.6rem 0.5rem 0; border-bottom: 1px solid var(--line); }
table.activity td { padding: 0.55rem 0.6rem 0.55rem 0; border-bottom: 1px solid var(--line); vertical-align: top; }
table.activity tr:last-child td { border-bottom: none; }
.badge { display: inline-block; font-size: 0.78rem; font-weight: 700; padding: 0.1rem 0.5rem; border-radius: 999px; white-space: nowrap; }
.badge.success { background: var(--ok-soft); color: var(--ok); }
.badge.info { background: var(--blue-soft); color: var(--blue); }
.badge.warning { background: var(--warn-soft); color: var(--warn); }
.badge.critical { background: var(--bad-soft); color: var(--bad); }
.badge.neutral { background: #eef0f4; color: var(--muted); }
.detail { display: block; color: var(--muted); font-size: 0.8rem; margin-top: 0.15rem; }

.footer { color: var(--muted); font-size: 0.85rem; text-align: center; margin-top: 1.5rem; }
.footer p { margin-top: 0.4rem; }
