@import url("https://fonts.googleapis.com/css2?family=Plus+Jakarta+Sans:wght@400;500;600;700;800&family=Sora:wght@500;600;700;800&display=swap");

:root {
  --bg-dark-1: #04183c;
  --bg-dark-2: #0a2b58;
  --text: #f2f5fb;
  --muted: #a9b8d9;
  --line-soft: rgba(185, 205, 244, 0.35);
  --panel-dark: rgba(8, 30, 66, 0.58);
  --pill: rgba(130, 154, 194, 0.2);
  --red: #c7222d;
  --brand-blue-700: #17345d;
  --brand-blue-800: #142b4f;
  --brand-blue-600: #183f71;
  --brand-blue-500: #5c7ba1;
  --brand-blue-400: #61799c;
  --brand-blue-300: #7890b1;
  --brand-accent: #d2574a;
  --brand-accent-strong: #d05f4d;
  --panel-border-light: rgba(202, 214, 232, 0.9);
  --panel-border-soft: rgba(205, 218, 236, 0.88);
  --panel-surface-light:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(244, 248, 253, 0.98));
  --panel-surface-crisp:
    linear-gradient(180deg, rgba(255, 255, 255, 0.99), rgba(245, 249, 253, 1));
  --panel-chip-bg: #f7fafd;
  --panel-chip-border: #dce6f1;
  --panel-shadow-soft: 0 16px 32px rgba(72, 95, 136, 0.1);
  --panel-shadow-card: 0 18px 34px rgba(7, 18, 36, 0.12);
  --radius-card-lg: 28px;
  --radius-card-md: 22px;
  --font-base: "Plus Jakarta Sans", "Segoe UI", "Inter", sans-serif;
  --font-nav: "Sora", "Plus Jakarta Sans", "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: var(--font-base);
  color: var(--text);
  background:
    radial-gradient(700px 500px at 8% 55%, rgba(178, 55, 76, 0.32), transparent 60%),
    radial-gradient(800px 540px at 80% 24%, rgba(38, 97, 182, 0.25), transparent 62%),
    linear-gradient(115deg, #021133 0%, var(--bg-dark-1) 34%, var(--bg-dark-2) 100%);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: #fff;
  color: #0b2450;
  padding: 0.5rem 0.8rem;
  z-index: 100;
  border-radius: 0 0 8px 8px;
}

.skip-link:focus {
  left: 14px;
}

*:focus-visible {
  outline: 2px solid #f7c78d;
  outline-offset: 2px;
}

.site-header {
  padding: 14px 14px 0;
}

.shell-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 18px;
}

.public-brand-row {
  display: flex;
  align-items: center;
  gap: 18px;
  min-width: 0;
}

.left-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-width: 320px;
  padding: 13px 19px;
  border-radius: 16px;
  text-decoration: none;
  color: #fff;
  background:
    linear-gradient(120deg, rgba(12, 52, 118, 0.98) 0%, rgba(244, 247, 252, 0.98) 42%, rgba(252, 252, 253, 0.98) 58%, rgba(163, 27, 39, 0.96) 100%);
  border: 1px solid rgba(255, 255, 255, 0.5);
  box-shadow:
    0 16px 30px rgba(4, 15, 38, 0.3),
    inset 0 1px 0 rgba(255, 255, 255, 0.34);
}

.left-badge-logo {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.95), rgba(226, 234, 248, 0.86));
  border: 1px solid rgba(15, 58, 128, 0.18);
  overflow: hidden;
  box-shadow: 0 10px 20px rgba(8, 22, 46, 0.18);
}

.left-badge-logo-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.left-badge-copy {
  display: grid;
  gap: 4px;
}

.left-badge strong {
  display: block;
  font-family: var(--font-nav);
  font-size: 1.18rem;
  line-height: 1.02;
  letter-spacing: 0.04em;
  font-weight: 800;
  text-transform: uppercase;
  color: #0d2f5f;
  text-shadow:
    0 1px 0 rgba(255, 255, 255, 0.52),
    0 10px 18px rgba(255, 255, 255, 0.12);
}

.left-badge small {
  display: block;
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #8f1f2a;
  opacity: 1;
}

.public-header-motto {
  display: inline-flex;
  align-items: center;
  color: rgba(255, 214, 190, 0.96);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.15rem, 1.8vw, 1.55rem);
  font-style: italic;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  white-space: nowrap;
  text-shadow: 0 8px 24px rgba(5, 15, 35, 0.28);
}

.public-header-motto::before {
  content: "";
  width: 54px;
  height: 1px;
  margin-right: 12px;
  background: linear-gradient(90deg, rgba(255, 214, 190, 0), rgba(255, 214, 190, 0.92));
}

.top-nav-frame {
  border: 1px solid rgba(187, 206, 240, 0.18);
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(9, 28, 58, 0.34), rgba(7, 23, 47, 0.22));
  padding: 8px 10px;
  box-shadow:
    0 14px 32px rgba(2, 10, 29, 0.22),
    inset 0 1px 0 rgba(255, 255, 255, 0.04);
  animation: navFloatIn 420ms ease-out both;
  backdrop-filter: blur(12px);
}

.top-nav {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-nav);
}

.pill-btn {
  position: relative;
  overflow: hidden;
  text-decoration: none;
  color: #eef4ff;
  font-weight: 700;
  font-size: 0.84rem;
  letter-spacing: 0.03em;
  background: rgba(131, 154, 194, 0.14);
  border: 1px solid rgba(163, 185, 222, 0.18);
  border-radius: 999px;
  padding: 11px 18px;
  transition: transform 0.25s ease, background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease, color 0.25s ease;
}

.pill-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(110deg, transparent 20%, rgba(255, 255, 255, 0.24) 46%, transparent 72%);
  transform: translateX(-130%);
  transition: transform 0.55s ease;
}

.pill-btn:hover {
  transform: translateY(-1px);
  color: #ffffff;
  border-color: rgba(220, 233, 255, 0.38);
  background: rgba(172, 192, 227, 0.18);
  box-shadow: 0 10px 22px rgba(8, 21, 48, 0.24), inset 0 0 0 1px rgba(233, 241, 255, 0.08);
}

.pill-btn:hover::before {
  transform: translateX(130%);
}

.pill-btn:active {
  transform: translateY(1px) scale(0.98);
}

.pill-btn.is-active {
  color: #07233f;
  background:
    linear-gradient(135deg, rgba(244, 248, 255, 0.96), rgba(208, 223, 247, 0.9));
  border-color: rgba(243, 248, 255, 0.74);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.92),
    0 10px 22px rgba(9, 23, 50, 0.22);
}

.pill-btn-primary {
  background: linear-gradient(130deg, #d84a40, #b1232b);
  border-color: rgba(246, 188, 191, 0.24);
  box-shadow: 0 12px 24px rgba(142, 28, 38, 0.24);
}

.pill-btn-primary:hover {
  background: linear-gradient(130deg, #df554a, #bd2830);
}

.pill-btn-primary.is-active {
  color: #fff7f5;
  background: linear-gradient(130deg, #de5c51, #bb2e35);
  border-color: rgba(255, 223, 226, 0.32);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.22),
    0 14px 28px rgba(142, 28, 38, 0.28);
}

.pill-btn-light {
  background: rgba(244, 248, 255, 0.92);
  color: #20395f;
  border-color: rgba(255, 255, 255, 0.28);
  box-shadow: 0 10px 22px rgba(7, 20, 42, 0.12);
}

.pill-btn-light:hover {
  background: #fff;
  color: #142f55;
}

.page-content {
  padding: 6px 10px 24px;
}

.toast-stack {
  position: fixed;
  left: 22px;
  bottom: 22px;
  z-index: 1400;
  display: grid;
  gap: 12px;
  width: min(420px, calc(100vw - 32px));
}

.toast {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 14px;
  align-items: center;
  padding: 16px 16px 16px 22px;
  border-radius: 20px;
  border: 1px solid rgba(163, 190, 235, 0.24);
  background:
    radial-gradient(180px 120px at 0% 50%, rgba(70, 222, 158, 0.13), transparent 72%),
    radial-gradient(220px 150px at 100% 0%, rgba(91, 138, 233, 0.2), transparent 68%),
    linear-gradient(145deg, rgba(17, 35, 67, 0.98), rgba(8, 20, 42, 0.98) 58%, rgba(5, 14, 31, 0.98));
  box-shadow:
    0 22px 44px rgba(4, 11, 26, 0.34),
    0 8px 24px rgba(17, 75, 161, 0.16),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
  animation: toastIn 280ms cubic-bezier(0.22, 1, 0.36, 1) both;
}

.toast::before {
  content: "";
  width: 5px;
  position: absolute;
}

.toast {
  position: relative;
  overflow: hidden;
}

.toast::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: 19px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.08), transparent 34%);
  pointer-events: none;
}

.toast::before {
  top: 12px;
  bottom: 12px;
  left: 10px;
  border-radius: 999px;
  background: linear-gradient(180deg, #89b6ff, #59d2ff);
  box-shadow: 0 0 18px rgba(97, 192, 255, 0.4);
}

.toast.success::before {
  background: linear-gradient(180deg, #63f0ae, #23c988);
  box-shadow: 0 0 18px rgba(63, 220, 143, 0.42);
}

.toast.error::before {
  background: linear-gradient(180deg, #ff8991, #ef5969);
  box-shadow: 0 0 18px rgba(240, 109, 120, 0.42);
}

.toast.warning::before {
  background: linear-gradient(180deg, #ffd47b, #f2b24f);
  box-shadow: 0 0 18px rgba(243, 196, 110, 0.38);
}

.toast-copy {
  position: relative;
  z-index: 1;
  color: #f3f8ff;
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.toast-close {
  position: relative;
  z-index: 1;
  width: 38px;
  height: 38px;
  padding: 0;
  border-radius: 13px;
  border: 1px solid rgba(192, 214, 248, 0.14);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 255, 255, 0.04));
  color: #e4eeff;
  font-size: 1.2rem;
  font-weight: 600;
  line-height: 1;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.08),
    0 10px 20px rgba(3, 12, 28, 0.16);
  transition: transform 0.18s ease, background-color 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.toast-close:hover {
  transform: translateY(-1px);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.16), rgba(255, 255, 255, 0.06));
  border-color: rgba(208, 226, 255, 0.22);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.1),
    0 14px 24px rgba(3, 12, 28, 0.2);
}

.toast.is-leaving {
  animation: toastOut 220ms ease-in forwards;
}

.container-narrow {
  width: min(1080px, 92vw);
  margin: 0 auto;
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1rem;
}

.card {
  background: rgba(10, 27, 57, 0.65);
  border: 1px solid var(--line-soft);
  border-radius: 12px;
  padding: 14px;
}

.list {
  display: grid;
  gap: 0.8rem;
}

.empty-state {
  color: #d2ddf4;
  border: 1px dashed rgba(185, 205, 244, 0.4);
  border-radius: 12px;
  padding: 0.9rem;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.photo {
  margin: 0;
  overflow: hidden;
  border-radius: 12px;
  border: 1px solid var(--line-soft);
  background: rgba(6, 21, 47, 0.58);
}

.photo img {
  display: block;
  width: 100%;
  height: 170px;
  object-fit: cover;
}

.photo figcaption {
  padding: 10px;
}

.news-card-image {
  display: block;
  width: 100%;
  height: 220px;
  margin-bottom: 12px;
  border-radius: 10px;
  object-fit: cover;
}

input,
textarea,
select,
button {
  width: 100%;
  padding: 0.65rem;
  border-radius: 8px;
  border: 1px solid rgba(190, 206, 238, 0.4);
  background: rgba(7, 28, 58, 0.55);
  color: #fff;
}

label {
  display: inline-block;
  margin-bottom: 0.35rem;
  font-weight: 700;
}

textarea {
  resize: vertical;
}

button {
  cursor: pointer;
  background: linear-gradient(125deg, #c62832, #991522);
}

.form-row {
  display: grid;
}

.field-error {
  color: #ffd7dc;
  margin-top: 0.3rem;
}

.not-found {
  margin-top: 1rem;
}

.not-found h1 {
  margin-top: 0;
}

.link-card {
  text-decoration: none;
  color: #eef3ff;
  font-weight: 600;
}

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

@keyframes navFloatIn {
  from {
    opacity: 0;
    transform: translateY(-10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes toastIn {
  from {
    opacity: 0;
    transform: translateY(12px) translateX(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0) translateX(0);
  }
}

@keyframes toastOut {
  from {
    opacity: 1;
    transform: translateY(0) translateX(0);
  }
  to {
    opacity: 0;
    transform: translateY(8px) translateX(-12px);
  }
}

@media (max-width: 980px) {
  .shell-top {
    flex-wrap: wrap;
  }

  .public-brand-row {
    width: 100%;
    justify-content: space-between;
    gap: 10px;
  }

  .left-badge {
    min-width: 0;
    width: 100%;
  }

  .public-header-motto {
    font-size: 0.92rem;
    letter-spacing: 0.06em;
  }

  .public-header-motto::before {
    width: 22px;
    margin-right: 8px;
  }

  .top-nav-frame {
    width: 100%;
    padding: 10px;
    border-radius: 20px;
  }

  .top-nav {
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px;
  }

  .pill-btn {
    flex: 1 1 calc(50% - 8px);
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 640px) {
  .site-header {
    padding: 12px 12px 0;
  }

  .top-nav-frame {
    background: rgba(6, 22, 45, 0.3);
    padding: 8px;
  }

  .top-nav {
    display: grid;
    grid-template-columns: 1fr 1fr;
  }

  .pill-btn {
    min-height: 44px;
    padding: 10px 12px;
    font-size: 0.78rem;
    letter-spacing: 0.02em;
  }

  .pill-btn-primary,
  .pill-btn-light {
    grid-column: span 2;
  }

  .toast-stack {
    left: 12px;
    right: auto;
    bottom: 12px;
    width: min(360px, calc(100vw - 24px));
  }
}
