:root {
  --primary: #16324f;
  --secondary: #496a81;
  --button: #1e5c8a;
  --background: #f4f7fa;
  --surface: #ffffff;
  --text: #17202a;
  --muted: #657483;
  --border: #d9e2ea;
  --danger: #a52a2a;
  --success: #176b45;
  --shadow: 0 18px 50px rgba(20, 43, 63, 0.09);
  --radius-lg: 22px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --container: 1180px;
  --transition: 180ms ease;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  background: var(--background);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

body[data-style="compact"] { --radius-lg: 14px; --radius-md: 9px; --shadow: 0 10px 30px rgba(20, 43, 63, 0.07); }
body[data-style="soft"] { --radius-lg: 28px; --radius-md: 18px; --shadow: 0 22px 60px rgba(20, 43, 63, 0.10); }

a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button { color: inherit; }
img { max-width: 100%; }

.container { width: min(calc(100% - 40px), var(--container)); margin-inline: auto; }
.hidden { display: none !important; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid color-mix(in srgb, var(--border) 88%, transparent);
  background: color-mix(in srgb, var(--surface) 90%, transparent);
  backdrop-filter: blur(18px);
}
.header-inner { min-height: 72px; display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { display: inline-flex; align-items: center; gap: 11px; font-weight: 760; letter-spacing: -0.02em; }
.brand-mark {
  width: 34px; height: 34px; display: grid; place-items: center;
  border-radius: 10px; background: var(--primary); color: #fff;
  font-family: Georgia, serif; font-weight: 700; box-shadow: 0 8px 24px color-mix(in srgb, var(--primary) 22%, transparent);
}
.nav-actions { display: flex; align-items: center; gap: 8px; }
.nav-link { display: inline-flex; align-items: center; min-height: 40px; padding: 0 13px; border-radius: 10px; color: var(--muted); font-size: 0.94rem; font-weight: 650; transition: var(--transition); }
.nav-link:hover { color: var(--primary); background: color-mix(in srgb, var(--primary) 7%, transparent); }
.nav-admin { border: 1px solid var(--border); color: var(--text); background: var(--surface); }

.eyebrow { display: inline-block; color: var(--secondary); font-size: 0.74rem; line-height: 1.2; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; }

.button {
  border: 0; cursor: pointer; min-height: 44px; padding: 0 18px; border-radius: 11px;
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 730; font-size: 0.94rem; transition: transform var(--transition), box-shadow var(--transition), background var(--transition), border-color var(--transition);
}
.button:hover { transform: translateY(-1px); }
.button:active { transform: translateY(0); }
.button-primary { background: var(--button); color: #fff; box-shadow: 0 10px 24px color-mix(in srgb, var(--button) 24%, transparent); }
.button-primary:hover { box-shadow: 0 13px 30px color-mix(in srgb, var(--button) 30%, transparent); }
.button-secondary { background: var(--surface); color: var(--text); border: 1px solid var(--border); }
.button-ghost { background: transparent; color: var(--muted); border: 1px solid transparent; }
.button-full { width: 100%; }

.text-input {
  width: 100%; min-height: 44px; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px;
  color: var(--text); background: var(--surface); outline: none; transition: border-color var(--transition), box-shadow var(--transition);
}
.text-input:focus { border-color: color-mix(in srgb, var(--primary) 65%, var(--border)); box-shadow: 0 0 0 4px color-mix(in srgb, var(--primary) 10%, transparent); }
textarea.text-input { resize: vertical; }
.textarea-small { min-height: 100px; }
.field-label { display: block; margin-bottom: 7px; font-size: 0.83rem; font-weight: 760; color: color-mix(in srgb, var(--text) 88%, var(--muted)); }
.field-help { display: block; margin-top: 6px; color: var(--muted); font-size: 0.79rem; }
.stack-form { display: grid; gap: 16px; }
.form-message { min-height: 1.4em; margin: 0; color: var(--muted); font-size: 0.86rem; }
.form-message.error { color: var(--danger); }
.form-message.success { color: var(--success); }

.reveal { animation: reveal 520ms cubic-bezier(.2,.75,.25,1) both; }
@keyframes reveal { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: translateY(0); } }

.site-footer { margin-top: 80px; border-top: 1px solid var(--border); background: var(--surface); }
.footer-inner { min-height: 76px; display: flex; align-items: center; justify-content: space-between; gap: 20px; color: var(--muted); font-size: 0.88rem; }
.footer-inner > :first-child { color: var(--text); font-weight: 700; }

@media (max-width: 720px) {
  .container { width: min(calc(100% - 28px), var(--container)); }
  .header-inner { min-height: 64px; }
  .nav-link:not(.nav-admin) { display: none; }
  .nav-admin { min-height: 38px; padding-inline: 11px; font-size: 0.86rem; }
  .footer-inner { align-items: flex-start; flex-direction: column; justify-content: center; gap: 4px; }
}
