/* Салон-ателье «Одежда для окон» — одностраничный сайт */

:root {
  --navy: #1c346e;
  --navy-dark: #122247;
  --navy-mid: #2d4a8c;
  --yellow: #f7d145;
  --yellow-deep: #e6be2c;
  --cream: #f8f4eb;
  --cream-2: #efe8d6;
  --paper: #fffdf8;
  --ink: #1c1c1c;
  --muted: #5c584f;
  --line: #e4dcc8;
  --shadow: 0 10px 30px rgba(28, 52, 110, 0.1);
  --radius: 16px;
  --header-h: 4.25rem;
  --sticky-h: calc(4.35rem + env(safe-area-inset-bottom, 0px));
  --max: 70rem;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  --font-display: Palatino, "Palatino Linotype", "Book Antiqua", "Iowan Old Style", Georgia, "Times New Roman", serif;
}

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

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

body {
  margin: 0;
  overflow-x: hidden;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--cream);
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--navy);
  text-underline-offset: 0.18em;
}

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

:focus-visible {
  outline: 3px solid var(--yellow);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  z-index: 1000;
  background: var(--yellow);
  color: var(--navy-dark);
  font-weight: 650;
  padding: 0.5rem 0.9rem;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
}

.skip-link:focus {
  top: 0;
}

.wrap {
  width: min(100% - 1.75rem, var(--max));
  margin-inline: auto;
}

/* Header */

.header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(248, 244, 235, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  gap: 1rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  text-decoration: none;
  color: var(--navy);
}

.brand:hover {
  color: var(--navy);
}

.brand img {
  width: 2.75rem;
  height: 2.75rem;
  flex: 0 0 auto;
}

.brand-text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  line-height: 1.15;
}

.brand-kicker {
  font-size: 0.68rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 650;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  font-style: italic;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav {
  display: none;
  margin-left: auto;
  align-items: center;
  gap: 0.15rem 1.15rem;
}

.nav a {
  color: var(--navy);
  text-decoration: none;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 0.35rem 0;
}

.nav a:hover {
  color: var(--navy-mid);
  text-decoration: underline;
}

.header-cta {
  margin-left: auto;
  flex: 0 0 auto;
}

/* Buttons */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  min-height: 2.85rem;
  padding: 0.55rem 1.15rem;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  font-size: 0.98rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: background 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.btn svg {
  width: 1.2rem;
  height: 1.2rem;
  flex: 0 0 auto;
}

.btn-primary {
  background: var(--yellow);
  color: var(--navy-dark);
  box-shadow: 0 2px 0 var(--yellow-deep);
}

.btn-primary:hover {
  background: #ffe06a;
  color: var(--navy-dark);
}

.btn-secondary {
  background: transparent;
  color: var(--paper);
  border-color: rgba(247, 209, 69, 0.75);
}

.btn-secondary:hover {
  background: rgba(247, 209, 69, 0.12);
  color: var(--yellow);
}

.btn-ghost {
  background: var(--paper);
  color: var(--navy);
  border-color: var(--navy);
}

.btn-ghost:hover {
  background: var(--navy);
  color: var(--paper);
}

.btn-compact {
  min-height: 2.5rem;
  padding: 0.4rem 0.9rem;
  font-size: 0.88rem;
}

/* Hero */

.hero {
  background: var(--navy);
  color: var(--paper);
  padding-bottom: 2.75rem;
}

.hero-banner {
  background: var(--navy);
}

.hero-banner img {
  width: 100%;
  height: auto;
  display: block;
  background: var(--navy);
}

.hero-copy {
  padding-top: 1.75rem;
}

.hero h1 {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(1.7rem, 5.4vw, 2.75rem);
  line-height: 1.2;
  letter-spacing: -0.01em;
  color: var(--paper);
}

.hero-lead {
  margin: 0 0 1.4rem;
  max-width: 38rem;
  font-size: 1.08rem;
  color: rgba(255, 253, 248, 0.9);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
}

/* Sections */

.section {
  padding: 3.25rem 0;
}

.section h2 {
  margin: 0 0 0.85rem;
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 3.4vw, 2.15rem);
  line-height: 1.2;
  color: var(--navy);
}

.section-lead {
  margin: 0 0 1.6rem;
  max-width: 42rem;
  color: var(--muted);
}

.section-navy {
  background: var(--navy);
  color: var(--paper);
}

.section-navy h2 {
  color: var(--yellow);
}

.section-navy .section-lead {
  color: rgba(255, 253, 248, 0.86);
}

.section-paper {
  background: var(--paper);
}

/* Services */

.service-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
  margin: 0 0 1.5rem;
  padding: 0;
  list-style: none;
}

.service-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1rem 0.95rem 1.05rem;
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  box-shadow: 0 1px 0 rgba(28, 52, 110, 0.03);
}

.service-icon {
  width: 2.85rem;
  height: 2.85rem;
  border-radius: 12px;
  background: #fff4cc;
  color: var(--navy);
  display: grid;
  place-items: center;
}

.service-icon svg {
  width: 1.7rem;
  height: 1.7rem;
}

.service-card h3 {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.3;
  color: var(--navy);
  font-weight: 700;
}

.note {
  margin: 0;
  padding: 1rem 1.1rem;
  background: var(--cream-2);
  border-left: 4px solid var(--yellow);
  border-radius: 0 12px 12px 0;
  color: var(--navy-dark);
}

/* How to order */

.steps {
  display: grid;
  gap: 0.85rem;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: step;
}

.step {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 0.9rem;
  align-items: start;
  background: rgba(255, 253, 248, 0.06);
  border: 1px solid rgba(247, 209, 69, 0.22);
  border-radius: var(--radius);
  padding: 1rem 1rem 1.1rem;
}

.step-num {
  width: 2.2rem;
  height: 2.2rem;
  border-radius: 50%;
  background: var(--yellow);
  color: var(--navy-dark);
  font-weight: 800;
  display: grid;
  place-items: center;
  font-size: 1.05rem;
  flex: 0 0 auto;
}

.step p {
  margin: 0;
  padding-top: 0.25rem;
  font-size: 1.05rem;
}

/* Works placeholder */

.works-grid {
  display: grid;
  gap: 0.75rem;
}

.works-slot {
  min-height: 10.5rem;
  border: 2px dashed #cbbf9e;
  border-radius: var(--radius);
  background:
    repeating-linear-gradient(
      -45deg,
      transparent,
      transparent 10px,
      rgba(28, 52, 110, 0.03) 10px,
      rgba(28, 52, 110, 0.03) 20px
    );
  color: var(--muted);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  text-align: center;
  padding: 1.25rem;
}

.works-slot svg {
  width: 2rem;
  height: 2rem;
  opacity: 0.7;
  color: var(--navy);
}

.works-slot span {
  font-size: 0.95rem;
  font-weight: 600;
}

.works-slot:nth-child(3) {
  display: none;
}

.badge {
  display: inline-block;
  margin-bottom: 0.65rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  background: var(--cream-2);
  color: var(--navy);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

/* Contacts */

.contacts-grid {
  display: grid;
  gap: 1rem;
}

.contact-card {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.15rem 1.2rem 1.25rem;
  box-shadow: var(--shadow);
}

.contact-card h3 {
  margin: 0 0 0.55rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--navy);
  font-size: 1.02rem;
}

.contact-card h3 svg {
  width: 1.2rem;
  height: 1.2rem;
  color: var(--navy);
  flex: 0 0 auto;
}

.contact-card p,
.contact-card address {
  margin: 0;
  font-style: normal;
  color: var(--ink);
}

.contact-card ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.contact-card li + li {
  margin-top: 0.25rem;
}

.phones a,
.map-link,
.vk-link {
  font-weight: 650;
  text-decoration: none;
}

.phones a {
  white-space: nowrap;
}

.phones a:hover,
.map-link:hover,
.vk-link:hover {
  text-decoration: underline;
}

.map-link,
.vk-link {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.7rem;
}

/* Footer */

.footer {
  background: var(--navy-dark);
  color: rgba(255, 253, 248, 0.78);
  padding: 1.5rem 0 calc(1.5rem + var(--sticky-h));
  font-size: 0.92rem;
}

.footer .wrap {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
}

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

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

/* Mobile sticky CTA bar */

.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 90;
  display: flex;
  gap: 0.5rem;
  padding: 0.55rem 0.75rem calc(0.55rem + env(safe-area-inset-bottom));
  background: rgba(18, 34, 71, 0.96);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-top: 1px solid rgba(247, 209, 69, 0.25);
}

.sticky-cta .btn {
  flex: 1 1 0;
}

/* Show compact label on very small header CTA */
.btn-label-short {
  display: inline;
}

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

/* On phones keep a short header label so the name + button fit on one line. */
@media (min-width: 64rem) {
  .header-cta .btn-label-short {
    display: none;
  }

  .header-cta .btn-label-full {
    display: inline;
  }
}

@media (min-width: 40rem) {
  .wrap {
    width: min(100% - 2.5rem, var(--max));
  }

  .service-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 0.9rem;
  }

  .works-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .works-slot {
    min-height: 11.5rem;
  }

  .works-slot:nth-child(3) {
    display: flex;
  }

  .hero {
    padding-bottom: 3.5rem;
  }

  .hero-copy {
    padding-top: 2.1rem;
  }

  .section {
    padding: 4rem 0;
  }
}

@media (min-width: 64rem) {
  :root {
    --sticky-h: 0px;
  }

  .sticky-cta {
    display: none;
  }

  .footer {
    padding-bottom: 1.75rem;
  }

  .nav {
    display: flex;
  }

  .header-cta {
    margin-left: 1.25rem;
  }

  .brand img {
    width: 3rem;
    height: 3rem;
  }

  .brand-name {
    font-size: 1.18rem;
  }


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

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

  .step {
    grid-template-columns: 1fr;
    min-height: 100%;
  }

  .service-card {
    padding: 1.15rem 1.1rem 1.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}

@media print {
  .header,
  .sticky-cta,
  .hero-actions,
  .header-cta {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
  }

  .hero {
    background: #fff;
    color: #000;
  }

  .hero h1,
  .section-navy h2,
  .section h2 {
    color: #000;
  }

  a {
    color: #000;
  }
}
