:root {
  --ink: #17221f;
  --muted: #5b6a64;
  --paper: #f3f6f4;
  --white: #ffffff;
  --teal: #0f6b5c;
  --teal-dark: #0a4f44;
  --sand: #d9c3a1;
  --sand-soft: #efe6d7;
  --danger: #b42318;
  --success: #147a45;
  --warning: #9a6700;
  --info: #175cd3;
  --border: #d5ddd9;
  --shadow: 0 18px 40px rgba(23, 34, 31, 0.08);
  --radius: 18px;
  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body: 'Manrope', sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(217, 195, 161, 0.35), transparent 28%),
    linear-gradient(180deg, #f7faf8 0%, #eef4f1 45%, #f3f6f4 100%);
  min-height: 100vh;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1120px, calc(100% - 2rem));
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(12px);
  background: rgba(243, 246, 244, 0.88);
  border-bottom: 1px solid rgba(213, 221, 217, 0.8);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  min-height: 76px;
  max-height: 76px;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.8rem;
}

.brand-logo {
  width: 54px;
  height: 54px;
  object-fit: contain;
  flex-shrink: 0;
}

.site-header .brand {
  gap: 0;
}

.site-header .brand-logo {
  width: 128px;
  height: 128px;
  margin: 0;
  padding: 0;
}

.site-header .brand-text {
  margin: 0;
  padding: 0;
}

.brand-logo-sm {
  width: 48px;
  height: 48px;
}

.brand-logo-lg {
  width: 78px;
  height: 78px;
}

.site-footer .brand-logo,
.site-footer .brand-logo-sm {
  width: 120px;
  height: 120px;
  margin: 0;
  padding: 0;
}

.site-footer .footer-brand {
  gap: 0;
  align-items: center;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  min-width: 0;
}

.brand-text strong {
  font-family: var(--font-display);
  font-size: 1.55rem;
  letter-spacing: 0.02em;
}

.brand-text small {
  color: var(--muted);
  font-size: 0.72rem;
  max-width: 220px;
  line-height: 1.25;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-nav a:not(.btn) {
  color: var(--muted);
  font-weight: 600;
}

.site-nav a.active,
.site-nav a:hover {
  color: var(--teal-dark);
}

.nav-toggle {
  display: none;
  width: 42px;
  height: 42px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: white;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  padding: 0 10px;
}

.nav-toggle span {
  display: block;
  height: 2px;
  background: var(--ink);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0.8rem 1.25rem;
  font-weight: 700;
  cursor: pointer;
  transition: 0.2s ease;
  font-family: inherit;
}

.btn-sm {
  padding: 0.55rem 1rem;
  font-size: 0.92rem;
}

.btn-xs {
  padding: 0.35rem 0.7rem;
  font-size: 0.8rem;
  border-radius: 10px;
}

.btn-primary {
  background: var(--teal);
  color: white;
}

.btn-primary:hover {
  background: var(--teal-dark);
}

.btn-secondary {
  background: var(--sand-soft);
  color: var(--ink);
  border-color: #e2d4bc;
}

.btn-light {
  background: rgba(255, 255, 255, 0.16);
  color: white;
  border-color: rgba(255, 255, 255, 0.35);
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--ink);
}

.btn-success {
  background: var(--success);
  color: white;
}

.btn-danger {
  background: var(--danger);
  color: white;
}

.full-width {
  width: 100%;
}

.hero {
  min-height: calc(100vh - 76px);
  overflow: hidden;
}

.hero-slider {
  min-height: calc(100vh - 76px);
  position: relative;
  overflow: hidden;
  width: 100%;
}

.slide {
  min-height: calc(100vh - 76px);
  position: relative;
  display: none;
  width: 100%;
  background-size: cover;
  background-position: center;
  animation: fadeSlide 0.7s ease;
}

.slide.is-active {
  display: block;
}

.slide-fallback {
  background:
    linear-gradient(135deg, rgba(15, 107, 92, 0.92), rgba(10, 79, 68, 0.88)),
    radial-gradient(circle at 20% 20%, rgba(217, 195, 161, 0.35), transparent 40%);
}

.slide-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(10, 28, 24, 0.78), rgba(10, 28, 24, 0.28) 70%);
}

.slide-content {
  position: relative;
  z-index: 1;
  min-height: calc(100vh - 76px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: white;
  max-width: 720px;
  padding-block: 4rem;
}

.hero-logo {
  width: clamp(96px, 16vw, 140px);
  height: clamp(96px, 16vw, 140px);
  object-fit: contain;
  margin-bottom: 0.85rem;
  filter: drop-shadow(0 10px 24px rgba(0, 0, 0, 0.28));
  animation: riseIn 0.8s ease both;
}

.brand-full-name {
  margin: 0 0 0.35rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  font-size: clamp(0.78rem, 1.6vw, 0.95rem);
  color: rgba(255, 255, 255, 0.9);
  max-width: 28ch;
}

.brand-full-name.dark {
  color: var(--teal-dark);
}

.brand-hero {
  font-family: var(--font-display);
  font-size: clamp(3.8rem, 9vw, 6.5rem);
  margin: 0 0 0.3rem;
  line-height: 0.9;
  letter-spacing: 0.02em;
  animation: riseIn 0.9s ease 0.08s both;
}

.slide-title {
  font-family: var(--font-display);
  font-size: clamp(2rem, 5vw, 3.4rem);
  margin: 0 0 0.8rem;
  font-weight: 600;
  max-width: 18ch;
  line-height: 1.1;
  animation: riseIn 0.8s ease both;
}

.slide-caption {
  max-width: 40ch;
  margin: 0;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1rem, 2vw, 1.15rem);
  line-height: 1.55;
  animation: riseIn 0.9s ease 0.08s both;
}

.slide-content p,
.slide-type {
  max-width: 38ch;
  color: rgba(255, 255, 255, 0.88);
}

.hero-actions {
  display: flex;
  gap: 0.8rem;
  margin-top: 1.4rem;
  flex-wrap: wrap;
}

.slider-controls {
  position: absolute;
  right: 1.5rem;
  bottom: 1.5rem;
  z-index: 2;
  display: flex;
  gap: 0.5rem;
}

.slider-controls button,
.slider-dots button {
  border: 0;
  cursor: pointer;
}

.slider-controls button {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  color: white;
  font-size: 1.4rem;
}

.slider-dots {
  position: absolute;
  left: 50%;
  bottom: 1.5rem;
  transform: translateX(-50%);
  z-index: 2;
  display: flex;
  gap: 0.45rem;
}

.slider-dots button {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
}

.slider-dots button.is-active {
  background: white;
  width: 28px;
  border-radius: 999px;
}

.section {
  padding: 5rem 0;
}

.section-head {
  margin-bottom: 2rem;
}

.section-head h2,
.page-hero h1,
.content-block h2,
.form-intro h2,
.cta-inner h2 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 4vw, 3.2rem);
  margin: 0 0 0.5rem;
}

.section-head p,
.page-hero p,
.form-intro p,
.cta-inner p {
  color: var(--muted);
  margin: 0;
}

.stats-section {
  background:
    linear-gradient(180deg, rgba(15, 107, 92, 0.06), transparent),
    rgba(255, 255, 255, 0.55);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1rem;
}

.stat-item {
  padding: 1.5rem;
  border: 1px solid rgba(15, 107, 92, 0.12);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.75);
  box-shadow: var(--shadow);
}

.stat-number {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2rem, 3vw, 2.7rem);
  color: var(--teal-dark);
  margin-bottom: 0.25rem;
}

.stat-label {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.95rem;
}

.about-grid,
.split-block,
.detail-grid,
.admin-two-col {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 1.5rem;
}

.about-aside,
.content-block,
.form-wrap,
.cta-inner {
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  padding: 1.8rem;
  box-shadow: var(--shadow);
}

.about-aside ol {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--muted);
  line-height: 1.7;
}

.cta-section .cta-inner {
  text-align: center;
  background:
    linear-gradient(135deg, rgba(15, 107, 92, 0.1), rgba(217, 195, 161, 0.28)),
    white;
}

.page-hero {
  padding: 4rem 0 2rem;
}

.page-hero-brand {
  display: flex;
  align-items: center;
  gap: 1.1rem;
}

.page-hero-logo {
  width: clamp(72px, 12vw, 110px);
  height: clamp(72px, 12vw, 110px);
  object-fit: contain;
  flex-shrink: 0;
}

.page-hero h1 {
  font-family: var(--font-display);
  font-size: clamp(3rem, 7vw, 4.8rem);
  margin: 0;
  color: var(--teal-dark);
}

.page-hero .brand-full-name {
  margin-bottom: 0.2rem;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 0;
}

.footer-brand-text {
  margin: 0;
  padding: 0;
}

.footer-org-name {
  margin: 0.15rem 0 0.35rem;
  font-weight: 700;
  color: var(--ink);
}

.app-form {
  display: grid;
  gap: 1rem;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.app-form label,
.filter-form label {
  display: grid;
  gap: 0.4rem;
  font-weight: 600;
  color: var(--muted);
  font-size: 0.92rem;
}

.app-form input,
.app-form select,
.app-form textarea,
.filter-form select,
.filter-form input {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 0.8rem 0.9rem;
  font: inherit;
  color: var(--ink);
  background: white;
}

.form-grid .full {
  grid-column: 1 / -1;
}

.form-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.flash-wrap {
  padding-top: 1rem;
}

.flash {
  padding: 0.9rem 1rem;
  border-radius: 12px;
  margin-bottom: 0.6rem;
  font-weight: 600;
}

.flash-success {
  background: #e8f7ee;
  color: var(--success);
}

.flash-error {
  background: #fdecec;
  color: var(--danger);
}

.site-footer {
  margin-top: 3rem;
  padding: 2.5rem 0 1.5rem;
  border-top: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.55);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
}

.footer-inner p,
.footer-copy {
  color: var(--muted);
}

.footer-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.lead {
  font-size: 1.08rem;
  line-height: 1.7;
  color: var(--muted);
}

.note {
  margin-top: 1.5rem;
  color: var(--muted);
}

@keyframes fadeSlide {
  from {
    opacity: 0.35;
  }
  to {
    opacity: 1;
  }
}

@keyframes riseIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 900px) {
  .stats-grid,
  .about-grid,
  .split-block,
  .detail-grid,
  .admin-two-col,
  .form-grid {
    grid-template-columns: 1fr;
  }

  .nav-toggle {
    display: flex;
  }

  .site-nav {
    position: absolute;
    top: 76px;
    left: 0;
    right: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    background: rgba(243, 246, 244, 0.98);
    border-bottom: 1px solid var(--border);
  }

  .site-nav.is-open {
    display: flex;
  }

  .footer-inner {
    flex-direction: column;
  }
}
