/* Dresscode site — v9
 *
 * Same identity as the Mini App: denim ink, mustard thread, cool shirting
 * white with an oxford weave. The bold element is the phone showing the
 * day's look; the denim bands give the page its weight.
 */

@font-face {
  font-family: "Dresscode Serif";
  src: url("/static/fonts/dresscode-serif.woff") format("woff");
  font-weight: 400 700;
  font-display: swap;
}

:root {
  --paper: #f5f6f8;
  --white: #ffffff;
  --ink: #1f2a44;
  --ink-soft: #4a5470;
  --muted: #687089;
  --line: #dfe3ea;
  --denim: #1f2a44;
  --denim-2: #2b3a5e;
  --on-denim: #eef1f7;
  --on-denim-soft: #b9c2d8;
  --thread: #e0a93b;
  --tag: #f8ecd2;
  --board: #e8ebf0;
  --weave: rgba(31, 42, 68, 0.045);
  --serif: "Dresscode Serif", Georgia, "Times New Roman", serif;
  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Text", "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(0.2, 0.8, 0.2, 1);
  --spring: cubic-bezier(0.34, 1.4, 0.5, 1);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background-color: var(--paper);
  background-image:
    repeating-linear-gradient(0deg, var(--weave) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, var(--weave) 0 1px, transparent 1px 3px);
  color: var(--ink);
  font: 400 1.0625rem/1.6 var(--sans);
}
html[data-lang="en"] [lang="ru"], html[data-lang="ru"] [lang="en"] { display: none !important; }
a { color: var(--denim-2); text-underline-offset: 3px; }
:focus-visible { outline: 2px solid var(--thread); outline-offset: 3px; }
h1, h2, h3 { font-family: var(--serif); font-weight: 600; letter-spacing: -0.015em; margin: 0; }
p { margin: 0; }
.wrap { max-width: 1120px; margin: 0 auto; padding: 0 28px; }

/* ---------------------------------------------------------------- top */

header.top { display: flex; justify-content: space-between; align-items: center; padding: 26px 0 10px; }
/* The wordmark: a woven label, sewn on with mustard thread */
.brand {
  display: inline-block;
  padding: 6px 18px 8px;
  margin: 6px;
  background: var(--denim);
  outline: 6px solid var(--denim);
  border: 2px dashed var(--thread);
  border-radius: 5px;
  color: var(--on-denim);
  font: 600 clamp(1.5rem, 2.6vw, 2rem)/1.1 var(--serif);
  letter-spacing: 0.02em;
  text-decoration: none;
  transform: rotate(-1.5deg);
  box-shadow: 0 12px 24px -14px rgba(31, 42, 68, 0.6);
}
.langs { display: flex; gap: 4px; }
.langs a {
  padding: 6px 10px; border-radius: 999px;
  color: var(--muted); text-decoration: none; font-size: 0.9375rem; font-weight: 600;
}
.langs a[aria-current="true"] { background: var(--white); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }

/* --------------------------------------------------------------- hero */

.hero {
  display: grid; grid-template-columns: 1.1fr 1fr; gap: 56px; align-items: center;
  padding: 48px 0 96px;
}
.hero h1 { font-size: clamp(2.75rem, 6.4vw, 5.25rem); line-height: 1; margin-bottom: 26px; }
.hero .lead { font-size: 1.25rem; line-height: 1.55; color: var(--ink-soft); max-width: 31ch; margin-bottom: 34px; }
.cta {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 16px 26px; border-radius: 999px;
  background: var(--denim); color: var(--on-denim);
  font-weight: 600; font-size: 1.0625rem; text-decoration: none;
  box-shadow: 0 14px 28px -16px rgba(31, 42, 68, 0.8);
  transition: transform 0.2s var(--spring), background 0.2s;
}
.cta:hover { background: var(--denim-2); transform: translateY(-2px); }
.cta svg { width: 20px; height: 20px; fill: currentColor; }
.cta.thread { background: var(--thread); color: #2a1d05; }
.cta.thread:hover { background: #ebb648; }
.cta-note { display: block; margin-top: 14px; color: var(--muted); font-size: 0.9375rem; }

/* the phone */
.showcase { position: relative; display: flex; justify-content: center; }
.showcase::before {
  /* a denim swatch behind the phone */
  content: ""; position: absolute; inset: 8% 6% 4% 14%;
  background: var(--denim); border-radius: 28px; transform: rotate(4deg);
  box-shadow: inset 0 0 0 10px var(--denim), inset 0 0 0 12px var(--thread);
  opacity: 0.95;
}
.phone {
  position: relative;
  width: min(100%, 340px);
  padding: 12px;
  border-radius: 46px;
  background: #11151f;
  box-shadow: 0 40px 70px -30px rgba(17, 21, 31, 0.75), inset 0 0 0 2px #2a3245;
  transform: rotate(-2deg);
}
.screen {
  position: relative; overflow: hidden;
  border-radius: 36px;
  background: var(--paper);
  padding: 34px 16px 18px;
  font-size: 13px; line-height: 1.4;
}
.screen::before { /* the camera notch */
  content: ""; position: absolute; top: 10px; left: 50%; width: 88px; height: 22px;
  margin-left: -44px; border-radius: 12px; background: #11151f;
}
.app-bar { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.mini-label {
  padding: 2px 8px 3px; border: 1.2px dashed var(--thread); border-radius: 3px;
  outline: 3px solid var(--denim); background: var(--denim); color: var(--on-denim);
  font: 600 12px/1.1 var(--serif); margin: 3px;
}
.mini-pill { padding: 3px 9px; border-radius: 999px; background: var(--thread); color: #2a1d05; font-weight: 700; font-size: 11px; }
.screen .hello { font: 600 21px/1.15 var(--serif); }
.screen .weather { margin: 4px 0 10px; color: var(--muted); }
.screen .weather b { color: var(--ink); }
.mini-chips { display: flex; gap: 6px; margin-bottom: 12px; white-space: nowrap; overflow: hidden; }
.mini-chips > span { padding: 5px 10px; border-radius: 999px; background: var(--white); box-shadow: inset 0 0 0 1px var(--line); font-size: 11.5px; }
.mini-chips > span.on { background: var(--denim); color: var(--on-denim); box-shadow: none; }

/* the board (shared by the phone and the weather examples) */
.board {
  position: relative; aspect-ratio: 4 / 5; border-radius: 14px;
  background-color: var(--board);
  background-image:
    repeating-linear-gradient(0deg, var(--weave) 0 1px, transparent 1px 3px),
    repeating-linear-gradient(90deg, var(--weave) 0 1px, transparent 1px 3px);
  overflow: hidden;
}
.board::after {
  content: ""; position: absolute; inset: 7px; border: 1.3px dashed rgba(224, 169, 59, 0.75); border-radius: 9px; pointer-events: none;
}
.look { position: absolute; inset: 0; }
.look:not(.on) { visibility: hidden; }
.print {
  position: absolute; margin: 0;
  padding: 4px 4px 14px;
  background: #fbfbfa; border-radius: 2px;
  box-shadow: 0 1px 1px rgba(31, 42, 68, 0.14), 0 8px 14px -6px rgba(31, 42, 68, 0.4);
  transform: rotate(var(--r, 0deg));
}
.print svg { display: block; width: 100%; aspect-ratio: 4 / 5; background: #ebebe6; }
.print figcaption {
  position: absolute; left: 5px; right: 5px; bottom: 1px;
  font-size: 8.5px; color: #3a4258; white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.look.on .print { animation: drop 0.6s var(--spring) both; animation-delay: calc(var(--i, 0) * 80ms); }
@keyframes drop {
  from { opacity: 0; transform: translateY(-24px) rotate(0deg) scale(0.92); }
  to { opacity: 1; transform: rotate(var(--r, 0deg)); }
}
.tag {
  position: absolute; top: 14px; right: 12px; z-index: 2;
  padding: 5px 9px 5px 18px;
  background: var(--tag); color: var(--ink);
  border-radius: 2px 7px 7px 2px;
  font: 600 11px/1.2 var(--serif);
  box-shadow: 0 6px 12px -6px rgba(31, 42, 68, 0.5);
  transform: rotate(4deg); transform-origin: 8px 50%;
}
.tag::before {
  content: ""; position: absolute; left: 6px; top: 50%; width: 6px; height: 6px; margin-top: -3px;
  border-radius: 50%; background: var(--board); box-shadow: inset 0 0 0 1.3px var(--thread);
}
.tag small { display: block; font: 500 9.5px/1.2 var(--sans); color: var(--muted); }
.look.on .tag { animation: swing 1.1s var(--ease) both 0.3s; }
@keyframes swing { 0% { transform: rotate(-16deg); opacity: 0; } 40% { opacity: 1; } 62% { transform: rotate(9deg); } 100% { transform: rotate(4deg); } }
.screen .why { margin-top: 10px; color: var(--ink-soft); min-height: 3.6em; }
.dots { display: flex; justify-content: center; gap: 6px; margin-top: 10px; }
.dots i { width: 6px; height: 6px; border-radius: 50%; background: var(--line); transition: background 0.3s, width 0.3s; }
.dots i.on { width: 16px; border-radius: 3px; background: var(--thread); }

/* -------------------------------------------------------------- bands */

.band { background: var(--denim); color: var(--on-denim); padding: 92px 0; position: relative; }
/* a seam along the top and bottom of each denim band */
.band::before, .band::after {
  content: ""; position: absolute; left: 0; right: 0; border-top: 2px dashed var(--thread); opacity: 0.85;
}
.band::before { top: 12px; }
.band::after { bottom: 12px; }
.band h2 { color: var(--on-denim); }
.section-head { max-width: 640px; margin-bottom: 48px; }
.section-head h2 { font-size: clamp(2rem, 4vw, 3rem); line-height: 1.08; }
.section-head p { margin-top: 14px; font-size: 1.125rem; color: var(--muted); }
.band .section-head p { color: var(--on-denim-soft); }

.steps { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.steps li { padding: 26px 24px 28px; border-radius: 18px; background: var(--denim-2); }
.steps .num {
  display: inline-grid; place-items: center; width: 44px; height: 44px; margin-bottom: 18px;
  border-radius: 50%; border: 2px dashed var(--thread);
  font: 600 1.25rem/1 var(--serif); color: var(--thread);
}
.steps h3 { font-size: 1.375rem; color: var(--on-denim); margin-bottom: 8px; }
.steps p { color: var(--on-denim-soft); }

section.plain { padding: 96px 0; }

/* weather examples */
.weathers { display: grid; grid-template-columns: repeat(2, 1fr); gap: 28px; }
.weather-card {
  display: grid; grid-template-columns: 210px 1fr; gap: 26px; align-items: center;
  padding: 22px; border-radius: 22px; background: var(--white);
  box-shadow: 0 1px 2px rgba(31, 42, 68, 0.06), 0 20px 40px -28px rgba(31, 42, 68, 0.45);
}
.weather-card .when { font: 600 1.5rem/1.2 var(--serif); }
.weather-card .temp { display: inline-block; margin: 8px 0 12px; padding: 4px 12px; border-radius: 999px; background: var(--paper); font-weight: 600; font-size: 0.9375rem; }
.weather-card p { color: var(--ink-soft); }

/* plans */
.plans { display: grid; grid-template-columns: 1fr 1.15fr; gap: 28px; align-items: stretch; }
.plan { padding: 34px 32px; border-radius: 24px; background: var(--white); box-shadow: inset 0 0 0 1px var(--line); }
.plan h3 { font-size: 1.75rem; }
.plan .price { margin: 6px 0 22px; color: var(--muted); }
.plan ul { list-style: none; margin: 0 0 8px; padding: 0; display: grid; gap: 10px; }
.plan li { display: flex; gap: 10px; }
.plan li::before { content: "✓"; color: var(--denim-2); font-weight: 700; }
.plan.plus {
  position: relative; background: var(--denim); color: var(--on-denim); box-shadow: 0 30px 60px -36px rgba(31, 42, 68, 0.9);
}
.plan.plus::after { content: ""; position: absolute; inset: 10px; border: 2px dashed var(--thread); border-radius: 16px; pointer-events: none; }
.plan.plus h3 { color: var(--on-denim); }
.plan.plus .price { color: var(--on-denim-soft); }
.plan.plus .price b { color: var(--thread); font-size: 1.5rem; font-family: var(--serif); }
.plan.plus li::before { content: "✦"; color: var(--thread); }
.plan.plus .cta { position: relative; z-index: 1; margin-top: 18px; }

.data-note { display: grid; grid-template-columns: auto 1fr; gap: 22px; align-items: start; max-width: 760px; }
.data-note .lock {
  width: 56px; height: 56px; border-radius: 16px; display: grid; place-items: center;
  background: var(--white); box-shadow: inset 0 0 0 1px var(--line); font-size: 1.5rem;
}
.data-note h2 { font-size: 1.75rem; margin-bottom: 8px; }
.data-note p { color: var(--ink-soft); }

/* ------------------------------------------------------------- footer */

footer.site-footer { background: var(--denim); color: var(--on-denim-soft); padding: 54px 0 46px; }
footer.site-footer .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 22px; }
footer.site-footer a { color: var(--on-denim); text-decoration: none; margin-left: 22px; }
footer.site-footer a:first-child { margin-left: 0; }
footer.site-footer .brand { transform: rotate(-1.5deg); font-size: 1.375rem; box-shadow: none; outline-color: var(--denim-2); background: var(--denim-2); }

/* -------------------------------------------------- legal pages (prose) */

main.prose { max-width: 720px; padding: 32px 0 80px; }
main.prose h1 { font-size: clamp(2.25rem, 5vw, 3.25rem); margin-bottom: 8px; }
main.prose h2 { font-size: 1.5rem; margin: 38px 0 10px; }
main.prose p, main.prose li { color: var(--ink-soft); }
main.prose ul { padding-left: 1.2em; }
main.prose li { margin-bottom: 6px; }
.meta { color: var(--muted); }
body > .wrap > footer { padding: 30px 0 50px; border-top: 2px dashed var(--line); }
body > .wrap > footer a { margin-right: 22px; color: var(--muted); }

/* ------------------------------------------------------------- mobile */

@media (max-width: 880px) {
  .hero { grid-template-columns: 1fr; gap: 44px; padding: 28px 0 72px; }
  .steps { grid-template-columns: 1fr; gap: 16px; }
  .weathers, .plans { grid-template-columns: 1fr; }
  .band, section.plain { padding: 72px 0; }
}
@media (max-width: 520px) {
  .wrap { padding: 0 20px; }
  .weather-card { grid-template-columns: 1fr; }
  .weather-card .board { max-width: 260px; }
  .plan { padding: 28px 24px; }
  footer.site-footer a { margin-left: 0; margin-right: 18px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
