/* ==========================================================================
   CF1 Self Storage — Cloudflare-inspired styling
   Brand: orange #F6821F, navy #003682, off-white #FAFAFA
   ========================================================================== */

:root {
  --orange: #f6821f;
  --orange-dark: #d96a0d;
  --orange-light: #faad3f;
  --navy: #003682;
  --navy-dark: #00204f;
  --ink: #1d1d1f;
  --ink-soft: #4a4a55;
  --bg: #fafafa;
  --surface: #ffffff;
  --border: #e5e7eb;
  --border-strong: #d1d5db;
  --success: #16a34a;
  --error: #dc2626;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 12px 32px rgba(0, 54, 130, 0.15);
  --radius: 12px;
  --radius-sm: 6px;
  --radius-lg: 16px;
  --maxw: 1180px;
  --section-y: 96px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui,
    sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: var(--navy);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--orange);
}

h1,
h2,
h3,
h4 {
  font-family: inherit;
  letter-spacing: -0.02em;
  margin: 0 0 16px;
  color: var(--ink);
}

h1 {
  font-size: clamp(40px, 6vw, 72px);
  font-weight: 800;
  line-height: 1.05;
}

h2 {
  font-size: clamp(28px, 4vw, 44px);
  font-weight: 700;
  line-height: 1.15;
}

h3 {
  font-size: 22px;
  font-weight: 700;
  line-height: 1.3;
}

p {
  margin: 0 0 12px;
  color: var(--ink-soft);
}

.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

.section-title {
  text-align: center;
}

.section-subtitle {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 56px;
  font-size: 18px;
  color: var(--ink-soft);
}

/* ===== Buttons ===== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-family: inherit;
  font-weight: 600;
  font-size: 15px;
  line-height: 1;
  padding: 12px 22px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease,
    transform 0.15s ease, box-shadow 0.15s ease;
  white-space: nowrap;
}

.btn--lg {
  font-size: 17px;
  padding: 16px 28px;
}

.btn--primary {
  background: var(--orange);
  color: #fff;
}

.btn--primary:hover:not(:disabled) {
  background: var(--orange-dark);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn--primary:disabled {
  background: var(--border-strong);
  color: #fff;
  cursor: not-allowed;
}

.btn--ghost {
  background: transparent;
  color: #fff;
  border-color: rgba(255, 255, 255, 0.6);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
  border-color: #fff;
}

/* ===== Nav ===== */

.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}

.nav__inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  align-items: center;
  gap: 24px;
}

.nav__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-weight: 700;
}

.nav__brand:hover {
  color: var(--ink);
}

.nav__logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  background: var(--orange);
  color: #fff;
  font-weight: 800;
  font-size: 14px;
  border-radius: var(--radius-sm);
  letter-spacing: 0;
}

.nav__brand-text {
  font-size: 17px;
  letter-spacing: -0.01em;
}

.nav__links {
  display: flex;
  gap: 28px;
  margin-left: auto;
}

.nav__links a {
  color: var(--ink);
  font-weight: 500;
  font-size: 15px;
}

.nav__links a:hover {
  color: var(--orange);
}

.nav__cta {
  margin-left: 0;
}

@media (max-width: 720px) {
  .nav__links {
    display: none;
  }
  .nav__inner {
    gap: 12px;
  }
}

/* ===== Hero ===== */

.hero {
  background: linear-gradient(
    135deg,
    var(--orange) 0%,
    var(--orange-light) 50%,
    var(--navy) 100%
  );
  color: #fff;
  padding: 120px 0 140px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(
      circle at 20% 30%,
      rgba(255, 255, 255, 0.1) 0%,
      transparent 50%
    ),
    radial-gradient(
      circle at 80% 70%,
      rgba(255, 255, 255, 0.08) 0%,
      transparent 50%
    );
  pointer-events: none;
}

.hero__inner {
  position: relative;
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
  text-align: center;
}

.hero__eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 13px;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.85);
  margin-bottom: 20px;
}

.hero__title {
  color: #fff;
  margin-bottom: 24px;
  max-width: 16ch;
  margin-left: auto;
  margin-right: auto;
}

.hero__subtitle {
  color: rgba(255, 255, 255, 0.92);
  font-size: clamp(17px, 2vw, 21px);
  max-width: 640px;
  margin: 0 auto 36px;
}

.hero__ctas {
  display: flex;
  justify-content: center;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}

.hero__bullets {
  list-style: none;
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px 32px;
  padding: 0;
  margin: 0;
  color: rgba(255, 255, 255, 0.92);
  font-size: 15px;
  font-weight: 500;
}

.hero__bullets li {
  position: relative;
  padding-left: 22px;
}

.hero__bullets li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: #fff;
  font-weight: 800;
}

/* ===== Features ===== */

.features {
  padding: var(--section-y) 0;
  background: var(--bg);
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  transition: transform 0.2s ease, box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.feature-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.feature-card__icon {
  width: 48px;
  height: 48px;
  border-radius: var(--radius-sm);
  background: rgba(246, 130, 31, 0.12);
  color: var(--orange);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.feature-card__icon svg {
  width: 24px;
  height: 24px;
}

.feature-card p {
  margin-bottom: 0;
}

@media (max-width: 900px) {
  .features__grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Sizes ===== */

.sizes {
  padding: var(--section-y) 0;
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.sizes__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.size-card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  text-align: left;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease,
    border-color 0.15s ease;
}

.size-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
  border-color: var(--orange);
}

.size-card:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 2px;
}

.size-card--featured {
  border-color: var(--orange);
  box-shadow: 0 0 0 1px var(--orange);
}

.size-card__badge {
  position: absolute;
  top: -12px;
  right: 20px;
  background: var(--orange);
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 5px 10px;
  border-radius: 999px;
}

.size-card__dim {
  font-size: 32px;
  font-weight: 800;
  color: var(--navy);
  letter-spacing: -0.02em;
}

.size-card__price {
  font-size: 24px;
  font-weight: 700;
  color: var(--ink);
}

.size-card__price span {
  font-size: 14px;
  font-weight: 500;
  color: var(--ink-soft);
}

.size-card__fits {
  margin: 4px 0 16px;
  font-size: 14px;
  color: var(--ink-soft);
}

.size-card__cta {
  margin-top: auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--orange);
  font-weight: 600;
  font-size: 15px;
}

.size-card__cta::after {
  content: "→";
  transition: transform 0.15s ease;
}

.size-card:hover .size-card__cta::after {
  transform: translateX(3px);
}

@media (max-width: 900px) {
  .sizes__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .sizes__grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Apply form ===== */

.apply {
  padding: var(--section-y) 0;
  background: var(--bg);
}

.apply__inner {
  display: grid;
  grid-template-columns: 1fr 1.2fr;
  gap: 64px;
  align-items: start;
}

.apply__copy .section-title,
.apply__copy .section-subtitle {
  text-align: left;
  margin-left: 0;
}

.apply__copy .section-subtitle {
  margin-bottom: 24px;
}

.apply__bullets {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
  color: var(--ink-soft);
}

.apply__bullets li {
  position: relative;
  padding-left: 28px;
  font-weight: 500;
}

.apply__bullets li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 6px;
  width: 18px;
  height: 18px;
  background: rgba(246, 130, 31, 0.14);
  border-radius: 50%;
}

.apply__bullets li::after {
  content: "✓";
  position: absolute;
  left: 4px;
  top: 4px;
  color: var(--orange);
  font-weight: 800;
  font-size: 13px;
}

.apply__form {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px;
  box-shadow: var(--shadow-lg);
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.form-row--split > div {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row label {
  font-size: 14px;
  font-weight: 600;
  color: var(--ink);
}

.form-row label span {
  color: var(--orange);
}

.form-row input,
.form-row select,
.form-row textarea {
  font-family: inherit;
  font-size: 15px;
  padding: 11px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--ink);
  width: 100%;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--orange);
  box-shadow: 0 0 0 3px rgba(246, 130, 31, 0.18);
}

.form-row textarea {
  resize: vertical;
  min-height: 84px;
}

.form-row--turnstile {
  align-items: center;
  margin: 4px 0;
}

.form-row--submit {
  margin-top: 8px;
}

.form-row--submit .btn {
  width: 100%;
}

.form-status {
  margin: 12px 0 0;
  text-align: center;
  font-size: 14px;
  font-weight: 500;
}

.form-status[data-state="success"] {
  color: var(--success);
}

.form-status[data-state="error"] {
  color: var(--error);
}

@media (max-width: 900px) {
  .apply__inner {
    grid-template-columns: 1fr;
    gap: 32px;
  }
  .apply__copy .section-title,
  .apply__copy .section-subtitle {
    text-align: center;
    margin-left: auto;
    margin-right: auto;
  }
  .apply__bullets {
    align-items: flex-start;
    max-width: 360px;
    margin: 0 auto;
  }
  .form-row--split {
    grid-template-columns: 1fr;
  }
  .apply__form {
    padding: 24px;
  }
}

/* ===== Footer ===== */

.footer {
  background: var(--navy-dark);
  color: rgba(255, 255, 255, 0.85);
  padding: 64px 0 0;
}

.footer__inner {
  display: grid;
  grid-template-columns: 1.4fr repeat(3, 1fr);
  gap: 32px;
  padding-bottom: 48px;
}

.footer__brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-weight: 700;
  font-size: 17px;
}

.footer__col h4 {
  color: #fff;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 14px;
}

.footer__col p {
  color: rgba(255, 255, 255, 0.75);
  font-size: 14px;
  margin: 0 0 6px;
}

.footer__base {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  padding: 24px 24px;
  margin: 0 auto;
  max-width: var(--maxw);
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13px;
  color: rgba(255, 255, 255, 0.6);
}

.footer__badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
}

.footer__badge::before {
  content: "";
  display: inline-block;
  width: 12px;
  height: 12px;
  background: var(--orange);
  border-radius: 3px;
}

@media (max-width: 900px) {
  .footer__inner {
    grid-template-columns: 1fr 1fr;
  }
  .footer__base {
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 600px) {
  .footer__inner {
    grid-template-columns: 1fr;
  }
}
