/* Perena Credit — standalone page styles (taste-skill "product performs" direction, Perena palette and type kept). */
@font-face { font-family: "Jakarta"; src: url(assets/jakarta.ttf) format("truetype"); font-weight: 200 900; font-display: swap; }

:root {
  --bg: #fcfaf7; --tone: #f2f0e9; --tone-2: #e9e6dc; --surface: #ffffff;
  --ink: #090914; --muted: #595340; --accent: #6b40e0; --accent-ink: #ffffff; --deep: #1b1340;
  --m: clamp(16px, 2.2vw, 32px); --r: 4px;
  --ease: cubic-bezier(.2,.7,.2,1);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 400 17px/1.55 Jakarta, system-ui, sans-serif; -webkit-font-smoothing: antialiased; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

.btn, .apply button { display: inline-flex; align-items: center; justify-content: center; background: var(--accent); color: var(--accent-ink); border: 0; border-radius: var(--r); padding: 10px 18px; font: 500 15px Jakarta, sans-serif; text-decoration: none; cursor: pointer; transition: transform .15s var(--ease), background .15s; }
.btn:hover, .apply button:hover { background: #5a33c9; }
.btn:active, .apply button:active { transform: scale(.97); }

/* Bar */
.bar { display: flex; justify-content: space-between; align-items: center; padding: 20px var(--m); }
.mark { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 600; font-size: 16px; }
.bar nav { display: flex; align-items: center; gap: 28px; font-size: 15px; }
.bar nav a:not(.btn) { text-decoration: none; color: var(--muted); transition: color .15s; }
.bar nav a:not(.btn):hover, .bar nav a[aria-current] { color: var(--ink); }

/* Hero: sentence split by a picture frame */
.hero { display: grid; grid-template-columns: 1fr minmax(380px, 34vw) 1fr; grid-template-rows: auto auto; align-items: center; column-gap: 32px; row-gap: 40px; padding: 8vh var(--m) 72px; min-height: calc(100svh - 72px); }
.hero h1 { grid-column: 1 / -1; grid-row: 1; display: grid; grid-template-columns: subgrid; align-items: center; margin: 0; }
.hero h1 span { font-size: clamp(36px, 4vw, 64px); line-height: 1; font-weight: 500; letter-spacing: -.035em; }
.h-a { grid-column: 1; grid-row: 1; }
.h-b { grid-column: 3; grid-row: 1; text-align: right; }
.frame { grid-column: 2; grid-row: 2; margin: 0; overflow: clip; border-radius: var(--r); }
.frame img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: var(--r); }
.hero-foot { grid-column: 1; grid-row: 2; align-self: end; }
.hero-facts { grid-column: 3; grid-row: 2; align-self: end; justify-self: end; margin: 0; display: grid; gap: 14px; text-align: right; }
.hero-facts dt { font-size: 16px; color: var(--muted); }
.hero-facts dd { margin: 0; font-size: clamp(24px, 2.2vw, 34px); font-weight: 500; letter-spacing: -.02em; }
.hero-foot p { font-size: 18px; max-width: 30ch; margin: 0; }

/* Quote fragment (product UI) */
.quote { background: var(--surface); border: 1px solid #ddd9cd; border-radius: 12px; padding: 20px; font-size: 14px; } /* taste-skill-ignore: data-ui fragment */
.q-head { display: flex; justify-content: space-between; color: var(--muted); font-size: 13px; margin-bottom: 14px; }
.q-tag { color: var(--accent); font-weight: 500; }
.q-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid #eeebe3; color: var(--muted); flex-wrap: wrap; } /* taste-skill-ignore: data-ui fragment */
.q-amt { font-size: 18px; color: var(--ink); font-weight: 500; }
.q-amt input { width: 120px; border: 1px solid #ddd9cd; border-radius: 6px; padding: 6px 8px; font: inherit; color: inherit; text-align: right; background: var(--bg); }
.seg { display: inline-flex; background: var(--tone); border-radius: 8px; padding: 3px; }
.seg button { border: 0; background: none; font: 500 13px Jakarta, sans-serif; color: var(--muted); padding: 6px 12px; border-radius: 6px; cursor: pointer; }
.seg button[aria-pressed="true"] { background: var(--surface); color: var(--ink); box-shadow: 0 1px 2px rgba(0,0,0,.08); } /* taste-skill-ignore: data-ui control */
.q-row output { color: var(--ink); font-weight: 500; }
.q-row input[type=range] { width: 100%; accent-color: var(--accent); }
.q-out { margin: 14px 0 16px; display: grid; gap: 8px; }
.q-out div { display: flex; justify-content: space-between; }
.q-out dt { color: var(--muted); } .q-out dd { margin: 0; font-variant-numeric: tabular-nums; font-weight: 500; }
.q-total { padding-top: 10px; border-top: 1px solid #eeebe3; font-size: 16px; } /* taste-skill-ignore: data-ui fragment */

/* Command list */
.lend { padding: 180px var(--m) 160px; }
.cmd input { width: 100%; font: 500 clamp(26px, 3vw, 44px) Jakarta, sans-serif; letter-spacing: -.02em; background: var(--tone); border: 0; border-radius: var(--r); padding: .45em .6em; color: var(--ink); margin-bottom: 18px; }
.cmd input::placeholder { color: var(--muted); }
.cmd ul { list-style: none; margin: 0; padding: 0; }
.cmd li { display: grid; grid-template-columns: 1fr auto; align-items: center; padding: 8px .4em; border-radius: var(--r); cursor: pointer; transition: background .2s var(--ease), color .2s; }
.c-name { font-size: clamp(34px, 4.6vw, 76px); font-weight: 500; letter-spacing: -.035em; line-height: 1.1; }
.c-key { display: inline-grid; place-items: center; width: 1.6em; height: 1.6em; background: var(--tone); border-radius: 6px; font-size: 22px; font-weight: 500; }
.cmd li p { grid-column: 1 / -1; margin: 0; font-size: 17px; max-width: 640px; display: none; padding: 4px 0 10px; }
.cmd li[aria-selected="true"] { background: var(--accent); color: var(--accent-ink); }
.cmd li[aria-selected="true"] .c-key { background: rgba(255,255,255,.18); }
.cmd li[aria-selected="true"] p { display: block; }
.cmd li[aria-selected="true"] p a { color: #fff; }
.cmd li[hidden] { display: none; }

/* How it works: drag through the stages */
.how { display: grid; grid-template-columns: 1fr 1fr; grid-template-rows: 1fr auto; min-height: 88svh; }
.how-l { background: var(--tone); padding: 72px var(--m); }
.how-l h2 { font-size: clamp(36px, 4.4vw, 72px); line-height: 1.02; letter-spacing: -.035em; font-weight: 500; margin: 0 0 20px; max-width: 12ch; transition: opacity .2s; }
.how-l p { font-size: 18px; margin: 0; transition: opacity .2s; }
.how-r { background: var(--tone-2); display: grid; place-items: center; padding: 48px var(--m); }
.sheet { width: min(440px, 100%); background: var(--surface); border: 1px solid #ddd9cd; border-radius: 12px; padding: 20px; font-size: 14px; } /* taste-skill-ignore: data-ui fragment */
.s-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.s-status { font-size: 12px; font-weight: 500; padding: 4px 10px; border-radius: 999px; background: var(--tone); color: var(--muted); transition: background .2s, color .2s; }
.s-status.go { background: #e6f5ec; color: #17663a; }
.s-status.live { background: #efe9fd; color: var(--accent); }
.sheet dl { margin: 0; }
.sheet dl div { display: flex; justify-content: space-between; padding: 8px 0; border-top: 1px solid #eeebe3; } /* taste-skill-ignore: data-ui fragment */
.sheet dt { color: var(--muted); } .sheet dd { margin: 0; font-weight: 500; transition: color .2s; }
.how-track { grid-column: 1 / -1; padding: 28px var(--m) 36px; background: var(--tone); }
.how-track input { width: 100%; accent-color: var(--accent); height: 28px; }
.how-names { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); margin: 8px 0 0; padding: 0; font-size: 16px; color: var(--muted); }
.how-names li:nth-child(2) { text-align: center; transform: translateX(-17%); } .how-names li:nth-child(3) { text-align: center; transform: translateX(17%); } .how-names li:last-child { text-align: right; }
.how-names li.on { color: var(--ink); font-weight: 500; }

/* Offshore field */
.offshore { display: grid; grid-template-columns: 5fr 7fr; background: var(--deep); color: #fff; }
.off-text { padding: 120px var(--m); align-self: center; }
.off-text h2 { font-size: clamp(34px, 3.8vw, 60px); line-height: 1.02; letter-spacing: -.035em; font-weight: 500; margin: 0 0 24px; }
.off-text p { font-size: 19px; margin: 0; max-width: 460px; color: #e4defa; }
.offshore img { width: 100%; height: 100%; min-height: 420px; object-fit: cover; }

/* Apply: the quote beside the form */
.apply { padding: 200px var(--m) 160px; }
.apply h2 { font-size: clamp(34px, 3.8vw, 60px); letter-spacing: -.035em; font-weight: 500; margin: 0 0 12px; }
.apply-sub { font-size: 18px; margin: 0 0 48px; max-width: 60ch; }
.apply-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 32px; align-items: start; }
.lead { display: grid; gap: 16px; }
.lead .row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.lead label { display: grid; gap: 6px; font-size: 16px; color: var(--muted); }
.lead input, .lead select, .lead textarea { font: 400 17px Jakarta, sans-serif; color: var(--ink); background: var(--tone); border: 0; border-radius: var(--r); padding: 12px 14px; width: 100%; }
.lead textarea { resize: vertical; }
.lead input:focus, .lead select:focus, .lead textarea:focus { outline: 2px solid var(--accent); outline-offset: 0; }
.lead button { padding: 16px; font-size: 17px; }
.f-hint { margin: -4px 0 0; font-size: 16px; color: var(--muted); }
.f-hint a { color: var(--accent); }
.f-summary { margin: 4px 0 0; font-size: 16px; color: var(--muted); }
.f-summary b { color: var(--ink); font-weight: 500; }
.hp { position: absolute; left: -9999px; }
.form-msg { margin-top: 12px; font-size: 16px; }
.form-msg.ok { color: #17663a; } .form-msg.err { color: #b42318; }

/* Footer: a quiet line */
.foot { display: grid; grid-template-columns: 1fr auto 1fr; gap: 16px; padding: 160px var(--m) 30px; font-size: 15px; color: var(--muted); }
.f-links { display: flex; gap: 24px; } .f-links a { color: var(--ink); text-decoration: none; }
.foot > span:nth-child(3) { text-align: right; }
.fine { grid-column: 1 / -1; font-size: 16px; margin: 24px 0 0; max-width: 65ch; line-height: 1.5; }

/* Motion: entrances, staggered per section */
.rise { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.rise.in { opacity: 1; transform: none; }
.frame img { transition: transform 1.2s var(--ease); }
@media (prefers-reduced-motion: reduce) { .rise { opacity: 1; transform: none; transition: none; } html { scroll-behavior: auto; } }

/* Phone */
@media (max-width: 860px) {
  .bar nav a:not(.btn) { display: none; }
  .hero-facts { grid-column: 1; grid-row: 4; justify-self: start; text-align: left; grid-template-columns: repeat(3, auto); gap: 24px; }
  .hero-facts dd { font-size: 20px; }
  .hero { grid-template-columns: 1fr; min-height: 0; padding-top: 24px; row-gap: 20px; }
  .hero h1 span { font-size: 10vw; }
  .hero h1 { grid-column: 1; grid-template-columns: 1fr; row-gap: 20px; }
  .h-a, .h-b, .frame, .hero-foot { grid-column: 1; grid-row: auto; }
  .frame { grid-row: 2; }
  .hero-foot { grid-row: 3; }
  .h-b { text-align: right; }
  .hero-foot { padding-top: 8px; }
  .lend { padding: 120px var(--m) 100px; }
  .c-name { font-size: 8.5vw; } .c-key { display: none; }
  .how, .offshore { grid-template-columns: 1fr; }
  .how-r { order: -1; } .how-track { order: 0; }
  .offshore img { min-height: 280px; }
  .off-text { padding: 72px var(--m); }
  .apply { padding: 120px var(--m) 100px; }
  .apply-grid, .lead .row { grid-template-columns: 1fr; }
  .foot { grid-template-columns: 1fr; padding-top: 20svh; }
  .foot > span:nth-child(3) { text-align: left; }
}
/* Footer links wrap on phones rather than pushing the page sideways. */
.f-links { display: inline-flex; flex-wrap: wrap; gap: 6px 16px; min-width: 0; }
.foot > * { min-width: 0; }
