:root {
  --bg: #f6faf8;
  --surface: #ffffff;
  --surface-alt: #f2f8f5;
  --text: #1f2a24;
  --muted: #5f7266;
  --line: #dbe7df;
  --primary: #207c62;
  --primary-strong: #18634f;
  --primary-soft: #e4f3ed;
  --locked-bg: #edf1ef;
  --locked-text: #8a9590;
  --shadow: 0 16px 38px rgba(27, 45, 37, 0.08);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background:
    radial-gradient(900px 420px at 95% -5%, #d8efe6 0%, rgba(216, 239, 230, 0) 58%),
    linear-gradient(180deg, #fcfefd 0%, var(--bg) 66%);
  color: var(--text);
  font-family: "Nunito Sans", "Segoe UI", sans-serif;
}

.container {
  width: min(1120px, 94vw);
  margin: 0 auto;
}

.site-header {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
  position: sticky;
  top: 0;
  z-index: 10;
}

.header-inner {
  min-height: 70px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand {
  color: var(--text);
  text-decoration: none;
  font-family: "Lora", Georgia, serif;
  font-size: 1.48rem;
  font-weight: 700;
}

.header-link {
  color: var(--primary-strong);
  text-decoration: none;
  font-weight: 700;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
}

.header-link:hover {
  background: var(--surface-alt);
}

.header-nav {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.page-main {
  padding: 1.4rem 0 2.2rem;
}

.hero {
  margin-bottom: 1rem;
}

.hero.compact {
  margin-bottom: 0.8rem;
}

.eyebrow {
  margin: 0;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.76rem;
  color: var(--muted);
  font-weight: 800;
}

h1 {
  margin: 0.45rem 0 0.4rem;
  font-family: "Lora", Georgia, serif;
  font-size: clamp(2rem, 3.6vw, 2.8rem);
  line-height: 1.15;
}

h3 {
  margin: 0 0 0.5rem;
  font-family: "Lora", Georgia, serif;
  font-size: 1.38rem;
}

p {
  margin: 0;
  line-height: 1.72;
}

.muted {
  color: var(--muted);
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
  padding: 1rem;
}

.small-card {
  width: min(460px, 95vw);
}

.phase-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
  margin-top: 1.1rem;
}

.phase-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  height: 100%;
}

.phase-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.phase-card-link:hover .phase-card {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px rgba(27, 45, 37, 0.12);
}

.phase-card-image {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: block;
}

.phase-card-body {
  padding: 0.95rem;
  display: grid;
  gap: 0.5rem;
}

.btn {
  display: inline-block;
  text-decoration: none;
  border: 0;
  border-radius: 10px;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  font-family: inherit;
  font-size: 0.92rem;
  padding: 0.55rem 0.9rem;
  cursor: pointer;
}

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

.btn.btn-light {
  background: #fff;
  color: var(--primary-strong);
  border: 1px solid var(--line);
}

.btn.btn-light:hover {
  background: var(--surface-alt);
}

button.btn:disabled,
.disabled-link {
  opacity: 0.45;
  pointer-events: none;
}

.step-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.55rem;
}

.step-link {
  display: block;
  text-decoration: none;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem;
  background: #fff;
  color: var(--text);
}

.step-type {
  display: inline-block;
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #0f766e;
  border: 1px solid #b7ddd2;
  background: #ecfaf5;
  border-radius: 999px;
  padding: 0.1rem 0.5rem;
}

.step-title {
  display: block;
  margin-top: 0.35rem;
  font-weight: 700;
}

.step-state {
  display: block;
  margin-top: 0.25rem;
  font-size: 0.8rem;
  color: var(--muted);
}

.step-link.is-available {
  border-color: #8bc7b4;
  background: var(--primary-soft);
}

.step-link.is-completed {
  border-color: #96d4aa;
  background: #e9f8ed;
}

.step-link.is-locked {
  background: var(--locked-bg);
  color: var(--locked-text);
  border-color: #d8e0db;
}

.step-link.is-locked .step-type {
  color: #7e8a83;
  border-color: #d0d9d4;
  background: #eff3f1;
}

.step-content {
  margin-bottom: 1rem;
  max-width: 70ch;
  font-size: 1.03rem;
  line-height: 1.72;
}

.step-media {
  width: min(780px, 100%);
  border-radius: 12px;
  border: 1px solid var(--line);
  margin-bottom: 1rem;
  display: block;
}

.step-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-bottom: 0.8rem;
}

.done-pill {
  border: 1px solid #9ccdb1;
  color: #2b6c46;
  background: #ebf8ef;
  padding: 0.5rem 0.7rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
}

.stack {
  display: grid;
  gap: 0.6rem;
}

.text-link {
  display: inline-flex;
  margin-bottom: 0.45rem;
  color: var(--primary-strong);
  text-decoration: underline;
  text-underline-offset: 3px;
  font-weight: 700;
}

label {
  font-size: 0.93rem;
  color: #2d3b35;
}

input[type='password'] {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font-size: 0.95rem;
  font-family: inherit;
}

input:not([type='file']),
textarea,
select {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font-size: 0.95rem;
  font-family: inherit;
  background: #fff;
}

textarea {
  resize: vertical;
  min-height: 120px;
}

.error {
  color: #b42318;
  font-weight: 700;
  margin-top: 0.35rem;
}

.notice {
  margin: 0.6rem 0 0.8rem;
  background: #eaf7ee;
  border: 1px solid #a8d5b8;
  color: #1e6041;
  border-radius: 10px;
  padding: 0.55rem 0.7rem;
  font-weight: 700;
}

.admin-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.admin-card {
  display: grid;
  gap: 0.8rem;
}

.admin-row {
  display: flex;
  justify-content: space-between;
  gap: 0.8rem;
  align-items: flex-start;
  flex-wrap: wrap;
}

.admin-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  align-items: center;
}

.btn-mini {
  padding: 0.4rem 0.65rem;
  font-size: 0.8rem;
}

.btn-danger {
  background: #b42318;
}

.btn-danger:hover {
  background: #8f1f17;
}

.admin-step-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.admin-step-list li {
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  align-items: center;
  flex-wrap: wrap;
}

code {
  background: #eef3f0;
  border: 1px solid #d5dfd8;
  border-radius: 7px;
  padding: 0.08rem 0.35rem;
}

@media (max-width: 780px) {
  .container {
    width: 100%;
    padding: 0 0.85rem;
  }

  .header-inner {
    min-height: 64px;
  }

  .brand {
    font-size: 1.24rem;
  }
}
