@import url('./fonts.css');

/* =========================================================================
   Resquiller Technologies

   Warm paper, near-black ink, the logo's teal for structure and a live cyan
   for anything you can touch. Deliberately NOT a dark ground with one neon
   accent — that is the house style of AI-generated web design.

   Type is inverted from the usual editorial treatment: Inter is the display
   face, set large and tight; the serif appears only as italic emphasis.

   One visual device: the loop. It needs no imagery, and it is the method.
   ========================================================================= */

:root {
    --paper:   #FAFAF8;
    --paper-2: #F1F0EC;
    --ink:     #14161A;
    --ink-2:   #5C626B;
    --ink-3:   #8B9199;
    --rule:    #E3E1DB;
    --rule-2:  #C9C6BE;

    --brand:   #0A4E68;   /* the mark */
    --live:    #0D7998;   /* anything you can touch */

    --sans:  'Inter', ui-sans-serif, system-ui, -apple-system, sans-serif;
    --serif: 'Newsreader', Georgia, serif;

    --gap: clamp(4.5rem, 3rem + 5vw, 8rem);
    --ease: cubic-bezier(.22, .61, .36, 1);
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
    background: var(--paper);
    color: var(--ink);
    font-family: var(--sans);
    font-size: 17px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
:focus-visible { outline: 2px solid var(--live); outline-offset: 3px; border-radius: 2px; }

.skip { position: absolute; left: -9999px; }
.skip:focus {
    left: 1rem; top: 1rem; z-index: 30;
    padding: .7rem 1.1rem; background: var(--paper);
    border: 1px solid var(--ink); text-decoration: none;
}

/* =========================================================================
   GRID — a numbered rail, then the content. Structure you can see.
   ========================================================================= */

.wrap { width: min(100% - 3rem, 74rem); margin-inline: auto; }

.row {
    display: grid;
    grid-template-columns: 8rem minmax(0, 1fr);
    gap: 0 3rem;
}

section { padding-block: var(--gap); border-top: 1px solid var(--rule); }

.n {
    font-size: .72rem;
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    letter-spacing: .1em;
    color: var(--ink-2);          /* 5.89:1 */
    padding-top: .55rem;
}
.n b { display: block; font-weight: 500; color: var(--brand); margin-bottom: .3rem; }

/* =========================================================================
   TYPE — Inter as the display face. Tight, confident. Not a serif page.
   ========================================================================= */

h1, h2 {
    font-weight: 600;
    letter-spacing: -.035em;
    line-height: 1.07;
    text-wrap: balance;
}

h1 { font-size: clamp(2.4rem, 1.4rem + 4.2vw, 4.4rem); max-width: 15ch; }
h2 { font-size: clamp(1.85rem, 1.3rem + 2.3vw, 3rem);  max-width: 17ch; }

/* the serif appears once per heading, as italic emphasis. that is its whole job. */
h1 em, h2 em {
    font-family: var(--serif);
    font-style: italic;
    font-weight: 400;
    letter-spacing: -.012em;
    color: var(--brand);
}

.lede {
    margin-top: 1.5rem;
    max-width: 40rem;
    font-size: clamp(1.05rem, 1rem + .35vw, 1.22rem);
    line-height: 1.62;
    color: var(--ink-2);
    text-wrap: pretty;
}
.lede em { font-family: var(--serif); font-style: italic; color: var(--ink); }
.lede + .lede { margin-top: 1rem; }

/* =========================================================================
   HERO
   ========================================================================= */

.hero { border-top: 0; padding-block: clamp(2.5rem, 2rem + 3vw, 4rem) var(--gap); }

.hero__top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
    padding-bottom: clamp(3rem, 2rem + 3vw, 5rem);
}
.hero__logo { width: 190px; }

.stamp {
    display: flex;
    gap: 1.4rem;
    font-size: .72rem;
    font-weight: 500;
    letter-spacing: .08em;
    color: var(--ink-2);          /* 5.89:1 — --ink-3 is 3.04:1 and this is text */
    font-variant-numeric: tabular-nums;
}

.hero__grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 3.5rem;
    align-items: center;
}
.hero__fig { display: flex; flex-direction: column; align-items: flex-start; }

/* =========================================================================
   THE GAP — the hero's diagram, and the page's whole argument.

   Two curves across a product's life. One is how much a stage actually decides
   whether the thing works. The other is where the effort actually goes. They
   are inverted, and the space between them at the left-hand edge is the reason
   this studio exists.

   It carries no numbers, because there are none to carry honestly. The shape
   is the claim.
   ========================================================================= */

.gap-chart { width: clamp(280px, 30vw, 380px); height: auto; overflow: visible; }

.gap-chart .axis   { stroke: var(--rule); stroke-width: 1; }
.gap-chart .band   { fill: var(--live); opacity: .10; }

.gap-chart .line   { fill: none; stroke-width: 2; stroke-linecap: round; }
.gap-chart .decide { stroke: var(--brand); }
.gap-chart .effort { stroke: var(--ink-3); stroke-dasharray: 5 3.5; }

.gap-chart .dot        { r: 3; }
.gap-chart .dot.decide { fill: var(--brand); }
.gap-chart .dot.effort { fill: var(--ink-3); }

.gap-chart .stage {
    font-family: var(--sans);
    font-size: 8px;
    font-weight: 600;
    letter-spacing: .09em;
    fill: var(--ink-2);          /* 5.89:1 — these are text, not hairlines */
    text-anchor: middle;
}
.gap-chart .key {
    font-family: var(--sans);
    font-size: 8.5px;
    font-weight: 600;
    letter-spacing: .02em;
}
.gap-chart .key.decide { fill: var(--brand); }
.gap-chart .key.effort { fill: var(--ink-2); }   /* text: needs 4.5:1 */

.gap-chart .note {
    font-family: var(--sans);
    font-size: 7.5px;
    font-weight: 500;
    letter-spacing: .06em;
    fill: var(--live);
    text-anchor: middle;
}

/* the lines draw themselves once, on arrival */
.js .gap-chart .line {
    stroke-dasharray: 480;
    stroke-dashoffset: 480;
    transition: stroke-dashoffset 1.1s var(--ease);
}
.js .gap-chart .effort { stroke-dasharray: 480; }
.js .gap-chart.seen .line { stroke-dashoffset: 0; }
.js .gap-chart.seen .effort { stroke-dasharray: 5 3.5; }

.gap-cap {
    margin-top: .9rem;
    font-size: .75rem;
    line-height: 1.5;
    letter-spacing: .01em;
    color: var(--ink-2);         /* 5.89:1 */
    max-width: 24rem;
}

/* =========================================================================
   THE LOOP — now in section 03, where the loop actually is.
   ========================================================================= */

.loop-mark { width: clamp(190px, 20vw, 240px); height: auto; margin-top: 2.5rem; }

.loop-mark .track { fill: none; stroke: var(--rule-2); stroke-width: 1; }
.loop-mark .arrow { fill: var(--rule-2); }
.loop-mark .node  { fill: var(--paper); stroke: var(--brand); stroke-width: 1.5; }
.loop-mark text {
    font-family: var(--sans);
    font-size: 7.5px;
    font-weight: 600;
    letter-spacing: .09em;
    fill: var(--ink-2);
    text-anchor: middle;
}
.loop-mark .runner { fill: var(--live); }

@keyframes orbit { to { transform: rotate(360deg); } }
.loop-mark .orbit {
    transform-origin: 100px 100px;
    animation: orbit 16s linear infinite;
}

/* =========================================================================
   PAIRS + ITEMS
   ========================================================================= */

.pairs {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
    gap: 2.5rem 3rem;
    margin-top: 3rem;
}

.item h3 {
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -.01em;
    margin-bottom: .55rem;
    padding-top: 1rem;
    border-top: 2px solid var(--ink);
}
.item p { font-size: .95rem; line-height: 1.65; color: var(--ink-2); }

/* the loop, listed */
.steps { margin-top: 3rem; }
.step {
    display: grid;
    grid-template-columns: 3rem minmax(0, 14rem) minmax(0, 1fr);
    gap: 1.5rem;
    align-items: baseline;
    padding: 1.35rem .75rem 1.35rem 0;
    border-top: 1px solid var(--rule);
    transition: background .18s var(--ease);
}
.step:last-child { border-bottom: 1px solid var(--rule); }
.step:hover { background: var(--paper-2); }

.step__n {
    font-size: .78rem;
    font-weight: 500;
    font-variant-numeric: tabular-nums;
    color: var(--live);
}
.step h3 { font-size: 1.1rem; font-weight: 600; letter-spacing: -.015em; }
.step p  { font-size: .95rem; color: var(--ink-2); line-height: 1.6; }

.again {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-top: 1.5rem;
    font-family: var(--serif);
    font-style: italic;
    font-size: 1.05rem;
    color: var(--brand);
}

/* =========================================================================
   THE INVERTED BAND — the one opinion on the page gets the one bold move.
   ========================================================================= */

.invert { background: var(--ink); color: var(--paper); border-top: 0; }
.invert h2 { color: var(--paper); }
.invert h2 em { color: #5FC4E4; }
.invert .lede { color: #A8AEB6; }
.invert .lede em { color: var(--paper); }
.invert .n { color: #626871; }
.invert .n b { color: #5FC4E4; }

/* =========================================================================
   NOT A FIT — plain rows. Facts, not boasts.
   ========================================================================= */

.nots { margin-top: 3rem; }
.not {
    display: grid;
    grid-template-columns: 1.6rem minmax(0, 16rem) minmax(0, 1fr);
    gap: 1.25rem;
    align-items: baseline;
    padding: 1.2rem 0;
    border-top: 1px solid var(--rule);
}
.not:last-child { border-bottom: 1px solid var(--rule); }
.not svg { color: var(--ink-3); align-self: center; }
.not h3 { font-size: 1.05rem; font-weight: 600; letter-spacing: -.01em; }
.not p  { font-size: .95rem; color: var(--ink-2); line-height: 1.6; }

/* =========================================================================
   BREADTH — insight, not a parade of industries
   ========================================================================= */

.breadth {
    margin-top: 2.75rem;
    padding-top: 1.75rem;
    border-top: 1px solid var(--rule);
    max-width: 44rem;
}
.breadth p { color: var(--ink-2); }
.breadth strong { color: var(--ink); font-weight: 600; }

/* =========================================================================
   FAQ
   ========================================================================= */

.faq { margin-top: 3rem; max-width: 46rem; }
.faq details { border-top: 1px solid var(--rule); }
.faq details:last-child { border-bottom: 1px solid var(--rule); }

.faq summary {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 0;
    cursor: pointer;
    list-style: none;
    font-size: 1.05rem;
    font-weight: 600;
    letter-spacing: -.01em;
    transition: color .18s var(--ease);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary:hover { color: var(--live); }
.faq summary::after {
    content: '';
    margin-left: auto;
    flex: none;
    width: 9px; height: 9px;
    border-right: 1.5px solid var(--ink-3);
    border-bottom: 1.5px solid var(--ink-3);
    transform: rotate(45deg) translateY(-2px);
    transition: transform .2s var(--ease);
}
.faq details[open] summary::after { transform: rotate(225deg) translateY(1px); }
.faq p { padding: 0 0 1.4rem; max-width: 42rem; font-size: .98rem; color: var(--ink-2); }

/* =========================================================================
   CONTACT
   ========================================================================= */

.mail {
    display: inline-flex;
    align-items: center;
    gap: .7rem;
    margin-top: 2rem;
    font-size: clamp(1.15rem, 1rem + 1vw, 1.75rem);
    font-weight: 600;
    letter-spacing: -.025em;
    text-decoration: none;
    color: var(--ink);
    border-bottom: 2px solid var(--live);
    padding-bottom: .2rem;
    transition: color .18s var(--ease), gap .18s var(--ease);
}
.mail:hover { color: var(--live); gap: 1.05rem; }

.where { margin-top: 1.75rem; font-size: .95rem; color: var(--ink-2); }

footer {
    padding-block: 2rem;
    border-top: 1px solid var(--rule);
    font-size: .8rem;
    color: var(--ink-2);          /* 5.89:1 */
    display: flex;
    justify-content: space-between;
    gap: 1rem;
}

/* =========================================================================
   MOTION — reveal on scroll. Enhancement only.
   ========================================================================= */

.js [data-in] {
    opacity: 0;
    transform: translateY(12px);
    transition: opacity .6s var(--ease), transform .6s var(--ease);
    transition-delay: var(--d, 0ms);
}
.js [data-in].seen { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .js [data-in] { opacity: 1; transform: none; transition: none; }
    .loop-mark .orbit { animation: none; }
    * { transition-duration: .01ms !important; }
}

/* =========================================================================
   SMALL SCREENS
   ========================================================================= */

@media (max-width: 900px) {
    .row { grid-template-columns: 1fr; gap: 1.25rem; }
    .n { padding-top: 0; display: flex; gap: .6rem; }
    .n b { margin: 0; }

    .hero__grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .loop-mark { width: 190px; }
    .gap-chart { width: 100%; }
    .hero__fig { align-items: stretch; }
    .hero__top { flex-direction: column; align-items: flex-start; gap: 1.25rem; }

    .step { grid-template-columns: 2.4rem 1fr; gap: .35rem 1rem; }
    .step p { grid-column: 2; }

    .not { grid-template-columns: 1.5rem 1fr; gap: .35rem 1rem; }
    .not p { grid-column: 2; }
}
