/* ============================================================
   COER ID — coerid.com  |  Theme inspired by CORTIS visual style
   ============================================================ */

:root {
  --bg:      #f4f2ed;
  --bg-alt:  #eae7e0;
  --ink:     #111;
  --ink-sub: #555;
  --paper:   #fff;
  --line:    #d4d0c8;
  --green:   #5a6b35;
  --green-l: #6b8c42;
  --green-d: #4a5a2c;
  --dark:    #111;
  --dark-2:  #1a1a1a;
  --dark-3:  #222;
  --white:   #fff;
  --radius:  16px;
  --radius-sm: 10px;
  --font:    'Inter', Arial, Helvetica, sans-serif;
  --font-display: 'Permanent Marker', cursive;
}

/* ---- Reset ---- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; }
body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  line-height: 1.6;
}
button, input, select { font: inherit; }
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }

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

/* ============================================================
   NAV
   ============================================================ */
.site-nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--dark);
  border-bottom: 1px solid rgba(255,255,255,.06);
  backdrop-filter: blur(12px);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  height: 64px;
  width: min(1200px, 92vw);
  margin: 0 auto;
}
.nav-brand {
  display: flex;
  align-items: center;
  gap: 8px;
}
.nav-logo {
  height: 28px;
  width: auto;
  filter: brightness(0) invert(1);
}
.nav-brand-text {
  font-family: var(--font-display);
  font-size: 24px;
  color: var(--white);
  letter-spacing: .02em;
}
.nav-links {
  display: flex;
  gap: 28px;
  margin-left: auto;
}
.nav-links a {
  color: rgba(255,255,255,.7);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .04em;
  transition: color .15s;
}
.nav-links a:hover { color: var(--white); }
.nav-cta {
  background: var(--green);
  color: var(--white);
  padding: 8px 20px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .03em;
  transition: background .15s;
  white-space: nowrap;
}
.nav-cta:hover { background: var(--green-l); }

.nav-menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--white);
  border-radius: 2px;
  transition: .2s;
}

/* ============================================================
   HERO / GENERATOR SECTION
   ============================================================ */
.hero-section {
  background: var(--bg);
  padding: 56px 0 64px;
}
.hero-header {
  text-align: center;
  margin-bottom: 40px;
}
.hero-header h1 {
  font-family: var(--font-display);
  font-size: clamp(36px, 6vw, 64px);
  line-height: 1.05;
  letter-spacing: .01em;
  margin-bottom: 12px;
}
.hero-accent {
  color: var(--green);
}
.hero-subtitle {
  font-size: 18px;
  color: var(--ink-sub);
  font-weight: 600;
  margin-bottom: 8px;
}
.hero-body {
  font-size: 15px;
  color: var(--ink-sub);
  max-width: 600px;
  margin: 0 auto;
  line-height: 1.65;
}

/* Generator workspace */
.generator-workspace {
  display: grid;
  grid-template-columns: minmax(300px, 380px) minmax(480px, 1fr);
  gap: 28px;
  align-items: start;
}

.controls-panel,
.preview-panel {
  background: var(--paper);
  border: 1px solid var(--line);
  box-shadow: 0 12px 48px rgba(0,0,0,.06);
  border-radius: var(--radius);
}

/* Controls */
.controls-panel {
  padding: 28px;
  position: sticky;
  top: 82px;
}
.step-block + .step-block { margin-top: 28px; }
.step-title {
  font-size: 13px;
  font-weight: 900;
  letter-spacing: .06em;
  margin-bottom: 6px;
  text-transform: uppercase;
}
.step-num {
  display: inline-flex;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green);
  color: var(--white);
  align-items: center;
  justify-content: center;
  margin-right: 8px;
  font-size: 11px;
  font-weight: 900;
}
.step-desc {
  font-size: 13px;
  color: var(--ink-sub);
  margin-bottom: 12px;
  line-height: 1.5;
}

/* Member grid */
.member-grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 8px;
}
.member-choice {
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: var(--radius-sm);
  padding: 0;
  overflow: hidden;
  cursor: pointer;
  transition: .18s;
  position: relative;
}
.member-choice img {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
}
.member-choice span {
  display: block;
  padding: 7px 2px;
  background: var(--dark);
  color: var(--white);
  font-size: 9px;
  font-weight: 900;
  text-align: center;
  letter-spacing: .02em;
}
.member-choice.active {
  outline: var(--green) solid 3px;
  outline-offset: 2px;
  transform: translateY(-2px);
}

/* Fields */
.fields { display: grid; gap: 12px; }
.fields label { display: grid; gap: 5px; }
.fields label span {
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .11em;
  text-transform: uppercase;
  color: var(--ink-sub);
}
.fields input,
.fields select {
  width: 100%;
  border: 1px solid var(--line);
  background: var(--bg);
  color: var(--ink);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  outline: none;
  transition: .15s;
}
.fields input:focus,
.fields select:focus {
  border-color: var(--green);
  box-shadow: 0 0 0 3px rgba(90,107,53,.15);
}

/* Buttons */
.primary-btn,
.secondary-btn {
  width: 100%;
  border-radius: var(--radius-sm);
  padding: 14px 16px;
  font-weight: 800;
  font-size: 14px;
  letter-spacing: .03em;
  cursor: pointer;
  transition: .15s;
}
.primary-btn {
  background: var(--green);
  color: var(--white);
  border: 1px solid var(--green);
  margin-top: 20px;
}
.primary-btn:hover { background: var(--green-l); border-color: var(--green-l); }
.secondary-btn {
  background: transparent;
  border: 1px solid var(--line);
  color: var(--ink);
  margin-top: 10px;
}
.secondary-btn:hover { border-color: var(--ink); }

/* Preview panel */
.preview-panel { padding: 24px; }
.preview-topline {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 0 2px 12px;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: .14em;
  color: var(--ink-sub);
  text-transform: uppercase;
}
.card-wrap {
  width: 100%;
  overflow-x: auto;
  padding: 4px 0 6px;
}

/* ============ COER CARD (unchanged from original) ============ */
.coer-card {
  min-width: 640px;
  position: relative;
  width: 100%;
  aspect-ratio: 1.6 / 1;
  background: linear-gradient(135deg, #fbfaf6, #f0eee8);
  border: 1px solid #bdb8ae;
  border-radius: 24px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(17,17,17,.12);
  display: grid;
  grid-template-columns: 34% 66%;
  grid-template-rows: 15% 85%;
  isolation: isolate;
}
.coer-card::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image: radial-gradient(rgba(0,0,0,.03) .8px, transparent .8px);
  background-size: 4px 4px;
  mix-blend-mode: multiply;
  z-index: 8;
}
.card-header {
  grid-column: 1 / 3;
  background: #111;
  display: flex;
  align-items: center;
  padding: 0 4.2%;
  z-index: 4;
}
.cortis-brand {
  height: 48%;
  display: flex;
  align-items: center;
  gap: 10px;
}
.cortis-brand img:first-child {
  height: 100%;
  width: auto;
  filter: brightness(0) invert(1);
}
.cortis-wordmark-text {
  color: #fff;
  font-size: clamp(22px, 2.6vw, 42px);
  font-weight: 900;
  letter-spacing: -.055em;
  line-height: 1;
}
.photo-column {
  grid-area: 2 / 1;
  padding: 6% 5.5% 4%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  z-index: 3;
}
.photo-frame {
  height: 80%;
  border: 2px solid #111;
  position: relative;
  background: #eee;
  overflow: hidden;
}
.photo-frame::before,
.photo-frame::after {
  content: '';
  position: absolute;
  width: 20px;
  height: 20px;
  border-color: #111;
  z-index: 2;
}
.photo-frame::before { left: -9px; top: -9px; border-left: 2px solid; border-top: 2px solid; }
.photo-frame::after { right: -9px; bottom: -9px; border-right: 2px solid; border-bottom: 2px solid; }
.photo-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 18%;
  display: block;
}
.id-number { margin-left: 18px; }
.id-number small { font-size: clamp(7px, .7vw, 11px); letter-spacing: .13em; display: block; margin-bottom: 3px; }
.id-number strong { display: inline-block; border: 2px solid #111; border-radius: 999px; padding: 2px 12px; font-size: clamp(14px, 1.65vw, 27px); }
.info-column {
  grid-area: 2 / 2;
  padding: 6% 13% 4% 4%;
  display: flex;
  flex-direction: column;
  z-index: 3;
}
.card-kicker { font-size: clamp(8px, .8vw, 12px); letter-spacing: .08em; margin-bottom: 3.5%; }
.info-row { border-bottom: 1px dashed #777; padding-bottom: 1.5%; margin-bottom: 2.5%; }
.info-row small { display: block; font-size: clamp(7px, .75vw, 12px); letter-spacing: .12em; margin-bottom: .6%; color: #3d3a36; }
.info-row strong { font-size: clamp(15px, 1.8vw, 26px); line-height: 1; display: block; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bottom-row { margin-top: auto; display: grid; grid-template-columns: 22% 1fr; gap: 8%; align-items: end; }
.fingerprint-box { aspect-ratio: 1; border: 1px solid #777; display: grid; place-items: center; background: rgba(255,255,255,.25); }
.fingerprint-lines {
  width: 58%; height: 70%; border-radius: 50%;
  background: repeating-radial-gradient(at 50% 70%, transparent 0, transparent 3px, #222 3px, #222 5px, transparent 5px, transparent 8px);
  opacity: .78;
}
.signature-block { border-bottom: 1px dashed #777; min-height: 60px; position: relative; display: flex; align-items: end; }
.signature-block small { position: absolute; left: 0; bottom: 6px; font-size: clamp(7px, .72vw, 11px); letter-spacing: .12em; }
.signature-block img { margin-left: 25%; width: 66%; height: 70px; object-fit: contain; object-position: center bottom; filter: contrast(1.25); }
.watermark { position: absolute; right: 12%; top: 23%; width: 42%; height: 62%; opacity: .055; z-index: 1; }
.watermark img { width: 100%; height: 100%; object-fit: contain; filter: grayscale(1) brightness(.25); }
.barcode { position: absolute; right: 4.5%; top: 28%; width: 3.2%; height: 50%; object-fit: fill; z-index: 3; }
.controls-panel > .primary-btn,
.controls-panel > .secondary-btn { display: none; }
.card-actions { display: flex; gap: 12px; margin-top: 14px; }
.card-actions .primary-btn { flex: 1; margin-top: 0; }
.card-actions .secondary-btn { flex: 1; margin-top: 0; }
.generator-note {
  text-align: center;
  font-size: 14px;
  color: var(--ink-sub);
  margin-top: 24px;
}

/* ============================================================
   DARK SECTION (What Is / FAQ)
   ============================================================ */
.dark-section {
  background: var(--dark);
  color: var(--white);
  padding: 80px 0;
}
.dark-section h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 44px);
  margin-bottom: 28px;
  letter-spacing: .01em;
}

/* About */
.about-content {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 48px;
  align-items: center;
}
.about-text p {
  color: rgba(255,255,255,.78);
  font-size: 15px;
  line-height: 1.75;
  margin-bottom: 16px;
}
.about-text p:last-child { margin-bottom: 0; }
.about-visual {
  display: flex;
  justify-content: center;
  align-items: center;
}
.about-card-mockup {
  width: 220px;
  height: 220px;
  border-radius: 28px;
  background: linear-gradient(135deg, var(--green-d), var(--green-l));
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.about-card-mockup img {
  width: 60px;
  height: 60px;
  filter: brightness(0) invert(1);
  opacity: .6;
}
.mockup-label {
  font-family: var(--font-display);
  font-size: 18px;
  color: rgba(255,255,255,.8);
}

/* FAQ */
.faq-list {
  max-width: 720px;
}
.faq-item {
  border-bottom: 1px solid rgba(255,255,255,.1);
}
.faq-item h3 {
  margin: 0;
  font-size: inherit;
  font-weight: inherit;
}
.faq-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 20px 0;
  background: none;
  border: none;
  color: var(--white);
  font-size: 16px;
  font-weight: 700;
  text-align: left;
  cursor: pointer;
  transition: color .15s;
}
.faq-trigger:hover { color: var(--green-l); }
.faq-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  position: relative;
}
.faq-icon::before,
.faq-icon::after {
  content: '';
  position: absolute;
  background: currentColor;
  border-radius: 2px;
  transition: transform .25s;
}
.faq-icon::before { width: 14px; height: 2px; top: 11px; left: 5px; }
.faq-icon::after { width: 2px; height: 14px; top: 5px; left: 11px; }
.faq-trigger[aria-expanded="true"] .faq-icon::after {
  transform: rotate(90deg);
}
.faq-answer {
  overflow: hidden;
  transition: max-height .3s ease, padding .3s ease;
}
.faq-answer p {
  color: rgba(255,255,255,.65);
  font-size: 15px;
  line-height: 1.7;
  padding-bottom: 20px;
}

/* ============================================================
   LIGHT SECTION (How To)
   ============================================================ */
.light-section {
  background: var(--bg-alt);
  padding: 80px 0;
}
.light-section h2 {
  font-family: var(--font-display);
  font-size: clamp(28px, 4vw, 44px);
  margin-bottom: 8px;
  text-align: center;
}
.section-intro {
  text-align: center;
  color: var(--ink-sub);
  font-size: 16px;
  margin-bottom: 40px;
}

/* Steps grid */
.steps-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.step-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 28px 24px;
  transition: transform .15s, box-shadow .15s;
}
.step-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(0,0,0,.08);
}
.step-card-num {
  display: inline-flex;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--green);
  color: var(--white);
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-weight: 900;
  margin-bottom: 14px;
}
.step-card-title {
  font-size: 16px;
  font-weight: 800;
  margin-bottom: 8px;
}
.step-card p {
  font-size: 14px;
  color: var(--ink-sub);
  line-height: 1.6;
}

/* ============================================================
   CTA SECTION
   ============================================================ */
.cta-section {
  background: var(--green);
  padding: 64px 0;
}
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}
.cta-title {
  font-family: var(--font-display);
  font-size: clamp(26px, 3.5vw, 40px);
  color: var(--white);
  margin-bottom: 8px;
}
.cta-text p {
  color: rgba(255,255,255,.82);
  font-size: 16px;
}
.cta-btn {
  display: inline-flex;
  align-items: center;
  background: var(--white);
  color: var(--green-d);
  padding: 14px 36px;
  border-radius: var(--radius-sm);
  font-weight: 800;
  font-size: 15px;
  white-space: nowrap;
  transition: .15s;
}
.cta-btn:hover { background: var(--bg); }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer {
  background: var(--dark);
  color: rgba(255,255,255,.5);
  padding: 48px 0 32px;
}
.footer-inner {
  display: grid;
  gap: 20px;
}
.footer-logo {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--white);
  margin-bottom: 4px;
}
.footer-tagline {
  font-size: 12px;
  color: rgba(255,255,255,.4);
}
.footer-links {
  display: flex;
  gap: 20px;
  font-size: 13px;
}
.footer-links a:hover { color: var(--white); }
.footer-disclaimer {
  font-size: 11px;
  line-height: 1.6;
  color: rgba(255,255,255,.35);
  max-width: 640px;
}
.footer-copy {
  font-size: 11px;
  color: rgba(255,255,255,.25);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1050px) {
  .generator-workspace { grid-template-columns: 1fr; }
  .controls-panel { position: relative; top: auto; }
  .preview-panel { order: -1; }
  .coer-card { min-width: 600px; }
  .card-wrap { overflow-x: auto; }
  .about-content { grid-template-columns: 1fr; }
  .about-visual { display: none; }
}

@media (max-width: 768px) {
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .cta-inner { flex-direction: column; text-align: center; }
}

@media (max-width: 700px) {
  /* Nav */
  .nav-links { display: none; }
  .nav-menu-btn { display: flex; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: var(--dark);
    padding: 16px 24px;
    gap: 16px;
    border-bottom: 1px solid rgba(255,255,255,.08);
  }

  /* Hero */
  .hero-section { padding: 32px 0 40px; }
  .hero-header { margin-bottom: 24px; }
  .hero-body { font-size: 14px; }

  /* Generator */
  .generator-workspace { display: flex; flex-direction: column; gap: 16px; }
  .controls-panel { order: 1; padding: 20px; border-radius: 14px; }
  .preview-panel { order: -1; padding: 14px; border-radius: 14px; overflow: visible; }
  .card-actions { flex-direction: column; gap: 8px; }

  .member-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 5px;
  }
  .member-choice span { font-size: 7px; padding: 5px 0; }

  /* Card */
  .card-wrap { overflow: visible; padding: 0 0 3px; }
  .coer-card {
    min-width: 0 !important;
    width: 100% !important;
    border-radius: 16px;
    position: relative !important;
  }
  .cortis-wordmark-text { font-size: clamp(13px, 5.3vw, 22px); }
  .photo-column { padding: 5.4% 5% 3%; }
  .photo-frame { border-width: 1px; }
  .id-number { margin-left: 4px; }
  .id-number small { font-size: 5.5px; margin-bottom: 1px; }
  .id-number strong { font-size: 10px; border-width: 1px; padding: 1px 6px; }
  .info-column { padding: 4.6% 12.5% 3.2% 4% !important; }
  .card-kicker { font-size: 6px; margin-bottom: 1.8% !important; }
  .info-row { padding-bottom: .7% !important; margin-bottom: 1.6% !important; }
  .info-row small { font-size: 5.2px; margin-bottom: .4%; }
  .info-row strong { font-size: clamp(9px, 3.7vw, 15px); }
  .bottom-row {
    left: 38.5%; right: 8.5%; bottom: 3.4%; height: 22%;
    z-index: 5; position: absolute !important; margin: 0 !important;
    display: grid !important; grid-template-columns: 22% 1fr !important;
    gap: 8% !important; align-items: end !important;
  }
  .fingerprint-box { width: 100%; height: auto; aspect-ratio: 1; align-self: end; border-width: .7px; }
  .signature-block { height: 100%; align-self: end; min-height: 0 !important; }
  .signature-block img { max-height: 44px; width: 66%; height: 92% !important; }
  .signature-block small { bottom: 2px; font-size: 5px; }

  /* Sections */
  .dark-section, .light-section { padding: 56px 0; }
  .steps-grid { grid-template-columns: 1fr; }
  .step-card { padding: 22px 20px; }
}

@media (max-width: 390px) {
  .hero-header h1 { font-size: 32px; }
  .member-grid { gap: 4px; }
  .member-choice span { font-size: 6px; }
}
