/* ==========================================================================
   Cooley Digital — shared styles
   Sections: 1. Tokens  2. Base  3. Layout  4. Components  5. Page sections
             6. Forms  7. Utilities  8. Responsive
   ========================================================================== */

/* 1. Tokens
   -------------------------------------------------------------------------- */
:root {
  --navy: #14213d;
  --navy-deep: #0d172b;
  --navy-soft: #1f2f52;
  --tan: #e8dcc8;        /* beige: page backgrounds + accent on navy */
  --tan-dark: #c9b08a;
  --tan-light: #f3ebdf;
  --tan-card: #efe5d5;   /* cards, steps, form panel */
  --tan-field: #f6f0e6;  /* form inputs */
  --tan-line: #a58962;   /* darker outline around boxes */
  --cream: #f5efe6;
  --white: #ffffff;
  --text: #14213d;
  --text-muted: #2c3b5e;
  --border: #a58962;
  --error: #b3261e;

  --font-heading: "Plus Jakarta Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 20px;

  --shadow-sm: 0 1px 2px rgba(20, 33, 61, 0.06), 0 1px 3px rgba(20, 33, 61, 0.08);
  --shadow: 0 4px 12px rgba(20, 33, 61, 0.08), 0 2px 4px rgba(20, 33, 61, 0.04);
  --shadow-lg: 0 16px 40px rgba(20, 33, 61, 0.14), 0 4px 10px rgba(20, 33, 61, 0.06);

  --container: 1120px;
  --gutter: 1.25rem;
  --section-y: 4.5rem;
  --header-h: 68px;

  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
}

/* 2. Base
   -------------------------------------------------------------------------- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: var(--header-h);
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: 1rem;
  line-height: 1.65;
  color: var(--text);
  background: var(--tan);
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main {
  flex: 1;
}

h1,
h2,
h3 {
  font-family: var(--font-heading);
  line-height: 1.15;
  letter-spacing: -0.02em;
  margin: 0 0 0.75rem;
  color: var(--navy);
}

h1 { font-size: clamp(2.25rem, 7vw, 3.75rem); font-weight: 800; }
h2 { font-size: clamp(1.75rem, 4.5vw, 2.5rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }

p {
  margin: 0 0 1rem;
}

a {
  color: var(--navy);
}

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

:focus-visible {
  outline: 3px solid var(--navy);
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}

/* 3. Layout
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.container--narrow {
  max-width: 760px;
}

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

.section--cream,
.section--tan { background: var(--tan); }
.section--tan + .section--tan,
.section--cream + .section--tan { border-top: 1px solid rgba(165, 137, 98, 0.35); }
.section--navy  { background: var(--navy); color: var(--white); }
.section--flush-top { padding-top: 0; }

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 2.75rem;
}

.section-header p {
  color: var(--text-muted);
  font-size: 1.0625rem;
  margin: 0;
}

.eyebrow {
  display: inline-block;
  font-family: var(--font-heading);
  font-size: 0.8125rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--navy);
  opacity: 0.8;
  margin-bottom: 0.75rem;
}

.hero .eyebrow {
  color: var(--tan);
  opacity: 1;
}

/* 4. Components
   -------------------------------------------------------------------------- */

/* Skip link */
.skip-link {
  position: absolute;
  left: 1rem;
  top: -100px;
  z-index: 100;
  background: var(--navy);
  color: var(--white);
  padding: 0.75rem 1rem;
  border-radius: var(--radius-sm);
  text-decoration: none;
  font-weight: 600;
}

.skip-link:focus {
  top: 1rem;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(232, 220, 200, 0.94);
  backdrop-filter: saturate(180%) blur(10px);
  -webkit-backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.25s var(--ease), box-shadow 0.25s var(--ease);
}

.site-header.is-scrolled {
  border-bottom-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
}

.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.125rem;
  letter-spacing: -0.02em;
  color: var(--navy);
  text-decoration: none;
  white-space: nowrap;
}

.wordmark__mark {
  display: grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  background: var(--navy);
  color: var(--tan);
  font-size: 1.125rem;
  font-weight: 800;
  flex-shrink: 0;
}

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

.site-nav__link {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.9375rem;
  color: var(--navy);
  text-decoration: none;
  border-bottom: 2px solid transparent;
  padding: 0.25rem 0;
  transition: border-color 0.2s var(--ease);
}

.site-nav__link:hover,
.site-nav__link[aria-current="page"] {
  border-bottom-color: var(--navy);
}

.wordmark--light { color: var(--white); }
.wordmark--light .wordmark__mark { background: var(--tan); color: var(--navy); }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.9375rem;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  border: 2px solid transparent;
  border-radius: 999px;
  padding: 0.8rem 1.35rem;
  cursor: pointer;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease),
    background-color 0.2s var(--ease), color 0.2s var(--ease), border-color 0.2s var(--ease);
}

.btn:hover {
  transform: translateY(-2px);
}

.btn:active {
  transform: translateY(0);
}

.btn__arrow {
  transition: transform 0.2s var(--ease);
}

.btn:hover .btn__arrow {
  transform: translateX(3px);
}

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

.btn--primary:hover {
  background: var(--navy-soft);
  box-shadow: var(--shadow);
}

.btn--tan {
  background: var(--tan);
  color: var(--navy);
}

.btn--tan:hover {
  background: var(--tan-light);
  box-shadow: 0 10px 24px rgba(232, 220, 200, 0.35);
}

.btn--lg {
  font-size: 1.0625rem;
  padding: 1.1rem 2rem;
}

.btn--block {
  width: 100%;
}

/* Header button: compact on small phones */
.site-header .btn {
  padding: 0.7rem 1.1rem;
  font-size: 0.875rem;
}

.btn-label-short { display: none; }

/* Cards */
.card {
  background: var(--tan-card);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
}

/* Footer */
.site-footer {
  background: var(--navy-deep);
  color: rgba(255, 255, 255, 0.75);
  padding: 3rem 0 2rem;
  font-size: 0.9375rem;
}

.site-footer__inner {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.site-footer__tagline {
  margin: 0.75rem 0 0;
  max-width: 320px;
}

.site-footer a {
  color: var(--tan);
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
}

.site-footer__heading {
  font-size: 1rem;
  color: var(--white);
  letter-spacing: 0;
  margin: 0 0 0.35rem;
}

.site-footer__contact p {
  margin: 0 0 0.35rem;
}

.site-footer__email {
  font-size: 1.0625rem;
  font-weight: 600;
}

.site-footer__links a {
  color: rgba(255, 255, 255, 0.75);
}

.site-footer__bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  margin-top: 2rem;
  padding-top: 1.5rem;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.55);
}

.site-footer__bottom p {
  margin: 0;
}

/* 5. Page sections
   -------------------------------------------------------------------------- */

/* Hero */
.hero {
  position: relative;
  background: var(--navy);
  color: var(--white);
  padding: 4.5rem 0 5rem;
  overflow: hidden;
  isolation: isolate;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(600px 400px at 85% 10%, rgba(232, 220, 200, 0.14), transparent 70%),
    radial-gradient(500px 360px at 0% 100%, rgba(31, 47, 82, 0.9), transparent 70%);
}

.hero h1 {
  color: var(--white);
  max-width: 15ch;
}

.hero h1 .accent {
  color: var(--tan);
}

.hero__sub {
  font-size: clamp(1.0625rem, 2.5vw, 1.25rem);
  color: rgba(255, 255, 255, 0.78);
  max-width: 38rem;
  margin-bottom: 2.25rem;
}

.hero__trust {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  list-style: none;
  padding: 0;
  margin: 2rem 0 0;
  font-size: 0.9375rem;
  color: rgba(255, 255, 255, 0.7);
}

.hero__trust li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.hero__trust svg {
  color: var(--tan);
  flex-shrink: 0;
}

.hero__area {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  margin: 1rem 0 0;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--tan);
}

.hero__area svg {
  flex-shrink: 0;
  margin-top: 0.15rem;
}

/* Work */
.work-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.75rem;
}

.work-card__media {
  position: relative;
  aspect-ratio: 16 / 10;
  background: linear-gradient(135deg, var(--cream), var(--tan-light));
  overflow: hidden;
  border-bottom: 2px solid var(--tan-line);
}

.work-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
  transition: transform 0.5s var(--ease);
}

.work-card:hover .work-card__media img {
  transform: scale(1.03);
}

/* Shown if the screenshot file is missing */
.work-card__media.is-missing img { display: none; }
.work-card__media.is-missing::after {
  content: "Screenshot coming soon";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--font-heading);
  font-weight: 600;
  color: var(--navy);
  opacity: 0.55;
}

.work-card__body {
  padding: 1.5rem 1.5rem 1.75rem;
}

.work-card__body p {
  color: var(--text-muted);
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-heading);
  font-weight: 700;
  color: var(--navy);
  text-decoration: none;
  border-bottom: 2px solid var(--tan-line);
  padding-bottom: 2px;
  transition: gap 0.2s var(--ease), border-color 0.2s var(--ease);
}

.text-link:hover {
  gap: 0.65rem;
  border-color: var(--navy);
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
  list-style: none;
  padding: 0;
  margin: 0;
  counter-reset: step;
}

.step {
  background: var(--tan-card);
  border-radius: var(--radius-lg);
  padding: 2rem 1.75rem;
  border: 2px solid var(--tan-line);
  transition: transform 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.step:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow);
}

.step__num {
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--tan);
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: 1.25rem;
  margin-bottom: 1.25rem;
}

.step p {
  color: var(--text-muted);
  margin: 0;
}

/* CTA band */
.cta-band {
  text-align: center;
}

.cta-band h2 {
  color: var(--white);
}

.cta-band p {
  color: rgba(255, 255, 255, 0.75);
  font-size: 1.125rem;
  max-width: 34rem;
  margin: 0 auto 2rem;
}

/* FAQ */
.section-header a {
  color: var(--navy);
  font-weight: 600;
}

.faq {
  display: grid;
  gap: 0.9rem;
}

.faq__item {
  background: var(--tan-card);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius);
  transition: box-shadow 0.2s var(--ease);
}

.faq__item:hover,
.faq__item[open] {
  box-shadow: var(--shadow);
}

.faq__item summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  padding: 1.15rem 1.35rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 1.0625rem;
  color: var(--navy);
  cursor: pointer;
  list-style: none;
}

.faq__item summary::-webkit-details-marker {
  display: none;
}

.faq__item summary::after {
  content: "+";
  flex-shrink: 0;
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--navy);
  color: var(--tan);
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1;
  transition: transform 0.2s var(--ease);
}

.faq__item[open] summary::after {
  transform: rotate(45deg);
}

.faq__item p {
  margin: 0;
  padding: 0 1.35rem 1.35rem;
  color: var(--text-muted);
}

/* Page intro (inner pages) */
.page-intro {
  background: var(--tan);
  padding: 3.5rem 0 3rem;
  text-align: center;
}

.page-intro p {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 36rem;
  margin: 0 auto;
}

/* Confirmation (thank-you) */
.confirm {
  text-align: center;
  padding: 5rem 0 6rem;
}

.confirm__icon {
  display: grid;
  place-items: center;
  width: 80px;
  height: 80px;
  margin: 0 auto 1.75rem;
  border-radius: 50%;
  background: var(--tan-card);
  border: 2px solid var(--tan-line);
  color: var(--navy);
  box-shadow: 0 0 0 10px rgba(165, 137, 98, 0.15);
}

.confirm p {
  font-size: 1.125rem;
  color: var(--text-muted);
  max-width: 32rem;
  margin: 0 auto 2.25rem;
}

/* Pricing */
.price-card {
  background: var(--tan-card);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 2rem 1.25rem;
  margin-top: -1.5rem;
  position: relative;
}

.badge {
  display: inline-block;
  background: var(--navy);
  color: var(--tan);
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8125rem;
  letter-spacing: 0.04em;
  border-radius: 999px;
  padding: 0.45rem 0.9rem;
  margin-bottom: 1.25rem;
}

.price-card__title {
  margin-bottom: 0.5rem;
}

.price-card__lead {
  color: var(--text-muted);
  margin-bottom: 1.75rem;
}

.price-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-bottom: 2rem;
}

.price-box {
  background: var(--tan-field);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.price-box__label {
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.8125rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin: 0 0 0.35rem;
}

.price-box__amount {
  font-family: var(--font-heading);
  font-weight: 800;
  font-size: clamp(2.5rem, 8vw, 3.25rem);
  line-height: 1;
  letter-spacing: -0.03em;
  color: var(--navy);
  margin: 0 0 0.5rem;
}

.price-box__amount small {
  font-size: 1.125rem;
  font-weight: 700;
  letter-spacing: 0;
  color: var(--text-muted);
}

.price-box p:last-child {
  margin: 0;
  color: var(--text-muted);
}

.check-list {
  list-style: none;
  padding: 0;
  margin: 0 0 2rem;
  display: grid;
  gap: 0.9rem;
}

.check-list li {
  display: flex;
  gap: 0.75rem;
  align-items: flex-start;
}

.check-list svg {
  flex-shrink: 0;
  margin-top: 0.2rem;
  color: var(--navy);
}

.check-list strong {
  color: var(--navy);
}

.price-card__actions {
  text-align: center;
}

.price-card__actions small {
  display: block;
  color: var(--text-muted);
  margin-top: 0.9rem;
}

/* 6. Forms
   -------------------------------------------------------------------------- */
.form-card {
  background: var(--tan-card);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 1.75rem 1.25rem;
  margin-top: -1.5rem;
  position: relative;
}

.form-note {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
}

.field label {
  font-weight: 600;
  font-size: 0.9375rem;
  color: var(--navy);
}

.req {
  color: var(--navy);
  font-weight: 700;
  margin-left: 0.15rem;
}

.optional {
  font-weight: 400;
  color: var(--text-muted);
  font-size: 0.8125rem;
  margin-left: 0.25rem;
}

.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit;
  font-size: 1rem; /* prevents iOS zoom on focus */
  color: var(--navy);
  background: var(--tan-field);
  border: 2px solid var(--tan-line);
  border-radius: var(--radius-sm);
  padding: 0.8rem 0.9rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  appearance: none;
  -webkit-appearance: none;
}

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

.field select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%2314213D' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  padding-right: 2.5rem;
  cursor: pointer;
}

.field input::placeholder,
.field textarea::placeholder {
  color: rgba(20, 33, 61, 0.5);
}

.field input:hover,
.field select:hover,
.field textarea:hover {
  border-color: var(--navy);
}

.field input:focus,
.field select:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--navy);
  box-shadow: 0 0 0 4px rgba(20, 33, 61, 0.18);
}

.field.has-error input,
.field.has-error select,
.field.has-error textarea {
  border-color: var(--error);
}

.field__error {
  font-size: 0.8125rem;
  color: var(--error);
  display: none;
}

.field.has-error .field__error {
  display: block;
}

.form-actions {
  margin-top: 2rem;
}

.form-actions small {
  display: block;
  text-align: center;
  color: var(--text-muted);
  margin-top: 0.9rem;
}

/* 7. Utilities
   -------------------------------------------------------------------------- */
.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* 8. Responsive (mobile first)
   -------------------------------------------------------------------------- */
@media (max-width: 479px) {
  .btn-label-full  { display: none; }
  .btn-label-short { display: inline; }
  .site-nav { gap: 0.75rem; }
}

@media (max-width: 379px) {
  .wordmark { font-size: 1rem; }
  .wordmark__mark { display: none; }
}

@media (min-width: 640px) {
  :root {
    --gutter: 1.75rem;
  }

  .form-card,
  .price-card {
    padding: 2.5rem;
  }

  .price-grid {
    grid-template-columns: 1fr 1fr;
  }

  .form-grid {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }

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

  .btn--block {
    width: auto;
    min-width: 280px;
  }

  .form-actions {
    text-align: center;
  }
}

@media (min-width: 768px) {
  :root {
    --section-y: 6rem;
    --header-h: 76px;
  }

  .site-header .btn {
    padding: 0.8rem 1.35rem;
    font-size: 0.9375rem;
  }

  .wordmark { font-size: 1.25rem; }

  .hero {
    padding: 6.5rem 0 7rem;
  }

  .work-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }

  .steps {
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
  }

  .site-footer__inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: flex-start;
  }

  .site-footer__contact {
    text-align: right;
  }

  .page-intro {
    padding: 4.5rem 0 4rem;
  }

  .form-card,
  .price-card {
    margin-top: -2rem;
    padding: 3rem;
  }

  .site-nav { gap: 1.75rem; }
}

@media (min-width: 1024px) {
  .hero {
    padding: 8rem 0 8.5rem;
  }

  .work-card__body {
    padding: 1.75rem 2rem 2rem;
  }
}
