:root {
  --orange: #e85d2b;
  --orange-dark: #c9471b;
  --ink: #172033;
  --muted: #5f6b7a;
  --paper: #f7f5f2;
  --white: #fff;
  --line: #e5e7eb;
  --shadow: 0 18px 50px rgba(23, 32, 51, .12);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--white); font: 16px/1.6 Inter, Arial, sans-serif; }
body.menu-open { overflow: hidden; }
img { display: block; max-width: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid #ffb38f; outline-offset: 3px; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 1000; padding: .7rem 1rem; background: var(--ink); color: white; }
.skip-link:focus { top: 1rem; }
.container { width: min(1120px, calc(100% - 2rem)); margin-inline: auto; }
.eyebrow { margin: 0 0 .6rem; color: var(--orange); font-size: .78rem; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.section { padding: 5.5rem 0; }
.section.alt { background: var(--paper); }
.section-head { max-width: 700px; margin-bottom: 2.5rem; }
.section-head h2, .split h2 { margin: 0 0 1rem; font-size: clamp(2rem, 5vw, 3.25rem); line-height: 1.1; }
.section-head p, .split p { color: var(--muted); }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 48px; padding: .75rem 1.15rem; border: 1px solid transparent; border-radius: .65rem; background: var(--orange); color: white; font-weight: 800; text-decoration: none; transition: .2s ease; }
.btn:hover { background: var(--orange-dark); transform: translateY(-2px); }
.btn-secondary { border-color: rgba(255,255,255,.5); background: rgba(255,255,255,.1); }
.btn-secondary:hover { background: white; color: var(--ink); }
.btn-dark { background: var(--ink); }

.topbar { padding: .45rem 0; background: var(--ink); color: #dce2ec; font-size: .86rem; }
.topbar-inner { display: flex; justify-content: space-between; gap: 1rem; }
.topbar a { color: white; font-weight: 700; text-decoration: none; }
.site-header { position: sticky; top: 0; z-index: 100; border-bottom: 1px solid var(--line); background: rgba(255,255,255,.96); backdrop-filter: blur(12px); }
.nav-wrap { display: flex; min-height: 86px; align-items: center; justify-content: space-between; gap: 1rem; }
.brand { display: flex; align-items: center; gap: .75rem; color: var(--ink); font-size: 1.45rem; font-weight: 900; text-decoration: none; }
.brand img { width: 56px; height: 56px; object-fit: contain; }
.brand-name { color: var(--ink); white-space: nowrap; }
.brand-name span { color: var(--orange); }
.nav { display: flex; align-items: center; gap: 1.4rem; }
.nav a { font-weight: 700; text-decoration: none; }
.nav a:hover { color: var(--orange); }
.menu-toggle { display: none; border: 0; background: none; font-weight: 800; }
.portfolio-nav { display: flex; align-items: center; gap: 1rem; }

.hero { position: relative; display: grid; min-height: 690px; place-items: center; overflow: hidden; background: #111827; color: white; }
.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: .45; }
.hero::after { position: absolute; inset: 0; content: ""; background: linear-gradient(90deg, rgba(10,17,30,.96), rgba(10,17,30,.48)); }
.hero-content { position: relative; z-index: 1; padding: 5rem 0; }
.hero-copy { max-width: 760px; }
.hero h1 { max-width: 750px; margin: 0 0 1.2rem; font-size: clamp(3rem, 8vw, 5.8rem); line-height: .98; letter-spacing: -.04em; }
.hero h1 span { color: #ff8b5d; }
.hero p { max-width: 650px; margin: 0 0 1.8rem; color: #e6ebf2; font-size: clamp(1.05rem, 2vw, 1.3rem); }
.actions { display: flex; flex-wrap: wrap; gap: .8rem; }
.trust-row { display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 2.5rem; color: #f0f3f8; font-weight: 700; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.2rem; }
.card { overflow: hidden; border: 1px solid var(--line); border-radius: 1rem; background: white; box-shadow: 0 8px 25px rgba(23,32,51,.07); }
.card img { width: 100%; aspect-ratio: 4/3; object-fit: cover; }
.card-body { padding: 1.25rem; }
.card h3 { margin: 0 0 .5rem; }
.card p { margin: 0; color: var(--muted); }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 3rem; align-items: center; }
.split-media { overflow: hidden; border-radius: 1.2rem; box-shadow: var(--shadow); }
.split-media img { width: 100%; min-height: 480px; object-fit: cover; }
.checks { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; padding: 0; list-style: none; }
.checks li::before { margin-right: .45rem; color: var(--orange); content: "✓"; font-weight: 900; }
.gallery-preview { display: grid; grid-template-columns: repeat(3, 1fr); gap: .8rem; }
.gallery-preview img { width: 100%; aspect-ratio: 4/3; border-radius: .8rem; object-fit: cover; }
.center { margin-top: 2rem; text-align: center; }
.social-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; }
.social-card { display: grid; gap: .45rem; min-height: 160px; padding: 1.4rem; border: 1px solid var(--line); border-radius: 1rem; background: white; box-shadow: 0 8px 25px rgba(23,32,51,.07); text-decoration: none; transition: .2s ease; }
.social-card:hover { border-color: var(--orange); transform: translateY(-3px); box-shadow: var(--shadow); }
.social-card strong { font-size: 1.2rem; }
.social-card span { color: var(--muted); }
.reviews-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1rem; margin-top: 2rem; }
.review-card { margin: 0; padding: 1.4rem; border-left: 4px solid var(--orange); border-radius: .8rem; background: var(--paper); }
.review-card blockquote { margin: .7rem 0 1rem; color: var(--ink); }
.review-card figcaption { color: var(--muted); font-weight: 800; }
.stars { color: var(--orange); letter-spacing: .15em; }

.contact-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 2rem; align-items: start; }
.contact-details { padding: 1.5rem; border-radius: 1rem; background: var(--ink); color: white; }
.contact-details a { display: block; margin: .7rem 0; color: white; font-weight: 800; text-decoration: none; }
.contact-details p { color: #d7deea; }
.form { display: grid; gap: 1rem; padding: 1.5rem; border: 1px solid var(--line); border-radius: 1rem; background: white; box-shadow: var(--shadow); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.field { display: grid; gap: .35rem; }
.field label { font-weight: 800; }
.field input, .field select, .field textarea { width: 100%; padding: .8rem; border: 1px solid #cbd1da; border-radius: .5rem; background: white; }
.field textarea { min-height: 130px; resize: vertical; }
.honeypot { position: absolute; left: -10000px; }
.form-status { min-height: 1.5rem; margin: 0; font-weight: 800; }
.form-status.success { color: #137a3b; }
.form-status.error { color: #b42318; }

.site-footer { padding: 2.5rem 0; background: #0d1422; color: #d1d8e3; }
.footer-grid { display: flex; justify-content: space-between; gap: 2rem; align-items: center; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1rem; }
.footer-links a { color: white; }
.legal { max-width: 820px; }
.legal h1 { font-size: clamp(2.4rem, 7vw, 4.5rem); line-height: 1; }

.portfolio-hero { padding: 5rem 0; background: var(--ink); color: white; text-align: center; }
.portfolio-hero h1 { margin: 0 0 .8rem; font-size: clamp(2.8rem, 8vw, 5rem); }
.portfolio-controls { display: flex; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; align-items: center; }
.portfolio-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: .75rem; }
.project { padding: 0; overflow: hidden; border: 0; border-radius: .7rem; background: #e8ebef; }
.project img { width: 100%; aspect-ratio: 1; object-fit: cover; transition: transform .25s; }
.project:hover img { transform: scale(1.04); }
.dialog { width: min(1100px, calc(100% - 2rem)); padding: 0; border: 0; border-radius: 1rem; background: #080d16; color: white; }
.dialog::backdrop { background: rgba(0,0,0,.88); }
.dialog img { width: 100%; max-height: 78vh; object-fit: contain; }
.dialog-bar { display: flex; justify-content: space-between; gap: 1rem; padding: .8rem; align-items: center; }
.icon-btn { min-width: 44px; min-height: 44px; border: 1px solid #526078; border-radius: 50%; background: transparent; color: white; font-size: 1.25rem; }

@media (max-width: 850px) {
  .nav { position: fixed; inset: 86px 0 auto; display: none; padding: 1.2rem; border-bottom: 1px solid var(--line); background: white; }
  .nav.open { display: grid; }
  .portfolio-nav { display: flex; }
  .menu-toggle { display: block; }
  .cards, .portfolio-grid, .social-grid, .reviews-grid { grid-template-columns: repeat(2, 1fr); }
  .split, .contact-grid { grid-template-columns: 1fr; }
  .topbar-inner, .footer-grid { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 540px) {
  .section { padding: 4rem 0; }
  .topbar { display: none; }
  .nav { inset-block-start: 86px; }
  .hero { min-height: 620px; }
  .hero h1 { font-size: 3rem; }
  .cards, .gallery-preview, .portfolio-grid, .social-grid, .reviews-grid, .form-row, .checks { grid-template-columns: 1fr; }
}

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

.language-switcher { display: flex; align-items: center; gap: .35rem; margin-left: auto; padding: .25rem .4rem; border: 1px solid var(--line); border-radius: 999px; background: white; }
.language-switcher button { padding: .25rem .35rem; border: 0; border-radius: 999px; background: transparent; color: var(--muted); font-size: .78rem; font-weight: 900; }
.language-switcher button.active { background: var(--ink); color: white; }
.privacy-notice { position: fixed; z-index: 500; right: 1rem; bottom: 1rem; left: 1rem; display: flex; width: min(920px, calc(100% - 2rem)); margin-inline: auto; padding: 1rem; border: 1px solid #3a465b; border-radius: 1rem; background: #0d1422; color: white; box-shadow: 0 20px 60px rgba(0,0,0,.35); align-items: center; justify-content: space-between; gap: 1.25rem; }
.privacy-notice p { margin: 0; }
.privacy-notice a { color: #ffb38f; font-weight: 800; }
.privacy-notice .btn { flex: 0 0 auto; }
@media (max-width: 850px) { .language-switcher { order: 2; margin-left: 0; } }
@media (max-width: 540px) { .privacy-notice { align-items: stretch; flex-direction: column; } }

/* Hero visual refinement */
.hero-bg { opacity: .68; filter: saturate(1.08) contrast(1.04); transform: scale(1.01); }
.hero::after { background: linear-gradient(90deg, rgba(8,14,25,.9) 0%, rgba(8,14,25,.56) 52%, rgba(8,14,25,.18) 100%); }
.hero-copy { position: relative; }
.hero-copy::before { display: block; width: 72px; height: 5px; margin-bottom: 1.25rem; border-radius: 999px; background: linear-gradient(90deg, #ff7a42, #ffc0a5); content: ""; }
.hero h1 { max-width: 820px; font-family: "Helvetica Neue", "Avenir Next", Avenir, Arial, sans-serif; font-weight: 900; letter-spacing: -.065em; text-wrap: balance; text-shadow: 0 8px 32px rgba(0,0,0,.28); }
.hero h1 span { display: inline-block; position: relative; color: #ff9a70; font-style: italic; letter-spacing: -.075em; }
.hero h1 span::after { position: absolute; right: .02em; bottom: -.08em; left: .04em; height: .09em; border-radius: 999px; background: linear-gradient(90deg, #ff6f35, #ffd0bc); content: ""; transform: rotate(-1deg); }
.card img, .gallery-preview img, .split-media img { filter: saturate(1.06) contrast(1.02); }

/* Mobile header and image-loading hardening */
img { height: auto; }
.hero-bg { height: 100%; }
@media (max-width: 850px) {
  .nav-wrap { display: grid; grid-template-columns: minmax(0, 1fr) auto auto; gap: .45rem; min-height: 74px; }
  .brand { min-width: 0; gap: .4rem; font-size: 1rem; }
  .brand img { width: 42px; height: 42px; flex: 0 0 42px; }
  .menu-toggle { grid-column: 3; grid-row: 1; padding: .5rem .65rem; border: 1px solid var(--line); border-radius: .55rem; background: var(--paper); }
  .language-switcher { grid-column: 2; grid-row: 1; order: initial; margin: 0; padding: .15rem .25rem; }
  .language-switcher button { padding: .2rem .25rem; font-size: .7rem; }
  .nav { inset: 74px 0 auto; }
  .portfolio-nav { grid-column: 2 / 4; grid-row: 1; justify-self: end; gap: .45rem; }
  .portfolio-nav > a:not(.btn) { display: none; }
  .portfolio-nav .btn { min-height: 42px; padding: .55rem .75rem; font-size: .8rem; }
  .portfolio-nav + .language-switcher { grid-column: 2; transform: translateX(-100%); }
}
@media (max-width: 380px) {
  .brand-name { display: none; }
  .brand { font-size: .82rem; }
}

/* Portfolio mobile header correction */
@media (max-width: 850px) {
  .portfolio-nav { grid-column: 2; grid-row: 1; }
  .portfolio-nav + .language-switcher { grid-column: 3; grid-row: 1; transform: none; }
}
