/*
Theme Name: 58 Glass & Glazing
Theme URI: https://58glassglazing.com
Author: 58 Glass & Glazing
Description: Premium custom theme for 58 Glass & Glazing.
Version: 1.0.5
Text Domain: fifty-eight-glass
*/

:root {
  --blue: #0878b8;
  --blue-bright: #1f98cf;
  --blue-light: #55b9df;
  --ink: #0b0f12;
  --muted: #5b646b;
  --line: #d9e0e4;
  --white: #ffffff;
  --serif: "Instrument Serif", Georgia, serif;
  --sans: "DM Sans", Arial, sans-serif;
  --max: 1320px;
  --header-h: 88px;
  --ease: cubic-bezier(.2,.8,.2,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; color: var(--ink); background: var(--white); font-family: var(--sans); font-size: 16px; line-height: 1.6; letter-spacing: 0; }
img { display: block; width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; letter-spacing: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
h1, h2, h3, p { margin-top: 0; }
h1, h2, h3 { text-wrap: balance; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.skip-link { position: fixed; left: 16px; top: -100px; z-index: 1000; padding: 12px 18px; background: var(--ink); color: #fff; transition: top .2s; }
.skip-link:focus { top: 16px; }

.site-header { height: var(--header-h); padding: 0 max(28px, calc((100vw - var(--max)) / 2)); display: grid; grid-template-columns: 270px 1fr auto; align-items: center; gap: 38px; background: rgba(255,255,255,.94); border-bottom: 1px solid rgba(11,15,18,.1); position: sticky; top: 0; z-index: 100; backdrop-filter: blur(16px); }
.brand { display: flex; align-items: center; width: 248px; height: 74px; overflow: hidden; }
.brand img { width: 238px; height: 89px; object-fit: contain; }
.primary-nav { display: flex; align-items: center; justify-content: flex-end; gap: clamp(24px, 3vw, 48px); }
.primary-nav a { position: relative; font-size: .9rem; font-weight: 600; }
.primary-nav a::after { content: ""; position: absolute; left: 0; right: 100%; bottom: -8px; height: 2px; background: var(--blue); transition: right .25s var(--ease); }
.primary-nav a:hover::after, .primary-nav a:focus-visible::after { right: 0; }
.menu-toggle { display: none; }

.button { min-height: 50px; display: inline-flex; align-items: center; justify-content: center; padding: 0 24px; border: 1px solid var(--blue); border-radius: 2px; font-size: .9rem; font-weight: 700; cursor: pointer; transition: transform .25s var(--ease), background .25s, color .25s, box-shadow .25s; }
.button:hover { transform: translateY(-2px); }
.button:focus-visible, .text-link:focus-visible, a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(31,152,207,.4); outline-offset: 3px; }
.button-solid { background: var(--blue); color: #fff; box-shadow: 0 10px 26px rgba(8,120,184,.16); }
.button-solid:hover { background: #056aa4; box-shadow: 0 14px 30px rgba(8,120,184,.24); }
.button:disabled { cursor: wait; opacity: .68; transform: none; }
.button-outline { color: var(--blue); background: rgba(255,255,255,.82); }
.button-outline:hover { background: #fff; }
.header-cta { min-height: 46px; }

.hero { min-height: calc(100svh - var(--header-h)); max-height: 900px; position: relative; display: flex; align-items: center; overflow: hidden; background: #f4f9fc; }
.hero-media { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 54% center; }
.hero-fade { position: absolute; inset: 0; background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.97) 24%, rgba(255,255,255,.67) 39%, rgba(255,255,255,0) 61%); }
.hero-content { width: min(620px, 46vw); margin-left: max(28px, calc((100vw - var(--max)) / 2)); position: relative; z-index: 2; padding: 72px 0 96px; }
.hero h1 { margin-bottom: 28px; font-family: var(--serif); font-size: clamp(4.3rem, 5.7vw, 6.8rem); font-weight: 400; line-height: .91; }
.hero p { max-width: 520px; margin-bottom: 34px; color: #30383e; font-size: clamp(1rem, 1.4vw, 1.16rem); line-height: 1.65; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.scroll-cue { position: absolute; z-index: 3; left: 50%; bottom: 22px; width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid rgba(255,255,255,.75); color: #fff; backdrop-filter: blur(8px); }
.scroll-cue svg { width: 21px; fill: none; stroke: currentColor; stroke-width: 1.7; animation: cue 2s ease-in-out infinite; }
@keyframes cue { 50% { transform: translateY(4px); } }

.proof-band { position: relative; z-index: 4; max-width: var(--max); margin: -24px auto 0; display: grid; grid-template-columns: repeat(3, 1fr); background: rgba(255,255,255,.9); border: 1px solid rgba(255,255,255,.9); box-shadow: 0 20px 55px rgba(20,56,75,.1); backdrop-filter: blur(18px); }
.proof-item { min-height: 156px; display: grid; grid-template-columns: 74px 1fr; gap: 22px; align-items: center; padding: 30px clamp(24px, 3vw, 42px); border-right: 1px solid var(--line); }
.proof-item:last-child { border-right: 0; }
.proof-item strong { font-family: var(--serif); color: var(--blue); font-size: 3.4rem; font-weight: 400; line-height: 1; }
.proof-item h2 { margin-bottom: 4px; font-family: var(--serif); font-size: 1.35rem; font-weight: 400; }
.proof-item p { margin: 0; color: var(--muted); font-size: .82rem; line-height: 1.55; }

.section { max-width: var(--max); margin: 0 auto; padding: 128px 28px; }
.section-label { margin-bottom: 12px; color: var(--blue); font-size: .75rem; font-weight: 700; text-transform: uppercase; }
.section-intro, .section-heading { display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(280px, .8fr); gap: 9vw; align-items: end; margin-bottom: 54px; }
.section-intro h2, .section-heading h2, .contact h2 { margin: 0; font-family: var(--serif); font-size: clamp(3rem, 5vw, 5.4rem); font-weight: 400; line-height: .95; }
.section-intro > p, .section-heading > p { max-width: 480px; margin: 0 0 6px; color: var(--muted); }

.service-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); border-left: 1px solid var(--line); }
.service { min-height: 294px; padding: 32px 30px 28px; display: flex; flex-direction: column; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); position: relative; overflow: hidden; transition: color .35s var(--ease), background .35s var(--ease), transform .35s var(--ease); }
.service::before { content: ""; position: absolute; inset: auto 0 0; height: 3px; background: var(--blue); transform: scaleX(0); transform-origin: left; transition: transform .35s var(--ease); }
.service:hover { background: #f4f9fc; transform: translateY(-3px); }
.service:hover::before { transform: scaleX(1); }
.service-number { width: 52px; height: 45px; margin-bottom: 28px; display: grid; place-items: center; color: var(--blue); border: 1px solid currentColor; clip-path: polygon(25% 0,75% 0,100% 50%,75% 100%,25% 100%,0 50%); font-size: .75rem; font-weight: 700; }
.service h3 { margin-bottom: 10px; font-family: var(--serif); font-size: 1.55rem; font-weight: 400; line-height: 1.05; }
.service p { margin-bottom: 22px; color: var(--muted); font-size: .86rem; line-height: 1.6; }
.service a { margin-top: auto; color: var(--blue); font-size: .76rem; font-weight: 700; text-transform: uppercase; }
.service a span { margin-left: 6px; font-size: 1rem; }

.section-dark { padding: 112px max(28px, calc((100vw - var(--max)) / 2)); color: #fff; background: #0a1116; }
.section-dark .section-label { color: var(--blue-light); }
.section-heading { max-width: var(--max); margin-left: auto; margin-right: auto; }
.section-heading .text-link { align-self: end; justify-self: end; }
.text-link { display: inline-flex; gap: 12px; align-items: center; color: var(--blue); font-size: .85rem; font-weight: 700; }
.section-dark .text-link { color: var(--blue-light); }
.text-link span { transition: transform .2s; }
.text-link:hover span { transform: translateX(5px); }
.project-grid { max-width: var(--max); margin: 0 auto; display: grid; grid-template-columns: 1.15fr 1fr 1fr; grid-template-rows: 260px 260px; gap: 12px; }
.project { margin: 0; position: relative; overflow: hidden; background: #111b21; }
.project-large { grid-row: span 2; }
.project-tall { grid-row: span 2; }
.project img { height: 100%; object-fit: cover; filter: saturate(.82); transition: transform .7s var(--ease), filter .45s; }
.project:hover img { transform: scale(1.035); filter: saturate(1); }
.project figcaption { position: absolute; inset: auto 0 0; padding: 46px 24px 18px; display: grid; color: #fff; font-family: var(--serif); font-size: 1.45rem; line-height: 1.05; background: linear-gradient(transparent, rgba(5,9,12,.8)); transform: translateY(8px); opacity: .92; transition: transform .3s, opacity .3s; }
.project:hover figcaption { transform: translateY(0); opacity: 1; }
.project figcaption span { margin-bottom: 4px; color: var(--blue-light); font-family: var(--sans); font-size: .68rem; font-weight: 700; text-transform: uppercase; }
.project:nth-child(4), .project:nth-child(5) { grid-column: 2; }

.process-intro { margin-bottom: 64px; }
.process-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.process-list li { min-height: 260px; padding: 34px 30px 20px; border-right: 1px solid var(--line); }
.process-list li:last-child { border-right: 0; }
.process-list span { display: block; margin-bottom: 38px; color: var(--blue); font-family: var(--serif); font-size: 3.7rem; line-height: 1; }
.process-list h3 { font-family: var(--serif); font-size: 1.5rem; font-weight: 400; line-height: 1.1; }
.process-list p { color: var(--muted); font-size: .86rem; }

.testimonials { padding-top: 54px; }
.testimonials .section-heading { align-items: center; }
.testimonials .section-heading > p { justify-self: end; font-size: .85rem; }
.quote-grid { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--line); }
.quote-grid blockquote { margin: 0; min-height: 280px; padding: 36px 42px; border-right: 1px solid var(--line); }
.quote-grid blockquote:last-child { border-right: 0; }
.quote-grid blockquote > span { display: block; height: 52px; color: var(--blue); font-family: var(--serif); font-size: 5rem; line-height: 1; }
.quote-grid blockquote p { font-family: var(--serif); font-size: 1.35rem; line-height: 1.45; }
.quote-grid footer { color: var(--muted); font-size: .72rem; font-weight: 700; text-transform: uppercase; }

.contact { min-height: 680px; display: grid; grid-template-columns: 1fr 1.08fr; background: #eff7fb; }
.contact-media { min-height: 680px; background: url("assets/images/contact-glass-interior.jpg") center / cover no-repeat; }
.contact-panel { margin: 54px 7vw 54px -42px; padding: 58px; align-self: center; background: rgba(255,255,255,.88); border: 1px solid rgba(255,255,255,.92); box-shadow: 0 24px 70px rgba(19,58,78,.16); backdrop-filter: blur(18px); }
.contact h2 { max-width: 650px; margin-bottom: 16px; font-size: clamp(3rem, 4.4vw, 5rem); }
.contact-panel > p:not(.section-label) { color: var(--muted); }
.contact-direct { display: flex; flex-wrap: wrap; gap: 8px 20px; }
.contact-direct a { color: var(--blue); font-size: .78rem; font-weight: 700; }
.contact-direct a:hover { text-decoration: underline; text-underline-offset: 4px; }
.quote-form-shell { margin-top: 30px; }
.quote-form-shell .ff-el-group { margin-bottom: 18px; }
.quote-form-shell .ff-el-input--label label { color: #2c3439; font-family: var(--sans); font-size: .72rem; font-weight: 700; }
.quote-form-shell input,
.quote-form-shell select,
.quote-form-shell textarea { width: 100%; margin-top: 7px; padding: 12px 13px; color: var(--ink); background: rgba(255,255,255,.78); border: 1px solid #cbd6dc; border-radius: 1px; font-family: var(--sans); font-size: .88rem; outline: none; transition: border .2s, box-shadow .2s; }
.quote-form-shell input,
.quote-form-shell select { min-height: 47px; }
.quote-form-shell textarea { min-height: 110px; resize: vertical; }
.quote-form-shell input:focus,
.quote-form-shell select:focus,
.quote-form-shell textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(8,120,184,.1); }
.quote-form-shell .ff-btn-submit { min-height: 50px; padding: 0 28px; color: #fff; background: var(--blue); border: 1px solid var(--blue); border-radius: 2px; font-family: var(--sans); font-size: .78rem; font-weight: 700; cursor: pointer; transition: background .2s, border-color .2s, transform .2s; }
.quote-form-shell .ff-btn-submit:hover { background: #075f91; border-color: #075f91; transform: translateY(-2px); }
.quote-form-shell .ff-el-is-error input,
.quote-form-shell .ff-el-is-error textarea { border-color: #a52a2a; }
.quote-form-shell .text-danger,
.quote-form-shell .error { color: #a52a2a; font-size: .72rem; }
.quote-form-shell .ff-message-success { padding: 16px 18px; color: #23623d; background: rgba(35,98,61,.08); border: 1px solid rgba(35,98,61,.2); }
.form-unavailable { color: #a52a2a; font-size: .82rem; }

.whatsapp-float { position: fixed; z-index: 90; right: 24px; bottom: 24px; min-height: 54px; padding: 0 19px 0 14px; display: inline-flex; align-items: center; gap: 10px; color: #fff; background: #128c7e; border: 1px solid rgba(255,255,255,.3); border-radius: 4px; box-shadow: 0 14px 34px rgba(5,38,34,.28); font-size: .82rem; font-weight: 700; transition: transform .25s var(--ease), background .25s, box-shadow .25s; }
.whatsapp-float:hover { color: #fff; background: #0d7569; transform: translateY(-3px); box-shadow: 0 18px 38px rgba(5,38,34,.34); }
.whatsapp-float svg { width: 28px; height: 28px; fill: currentColor; flex: 0 0 auto; }

.site-footer { padding: 72px max(28px, calc((100vw - var(--max)) / 2)) 24px; display: grid; grid-template-columns: 1.35fr .75fr .65fr 1fr; gap: 70px; color: #d8e2e7; background: #080d10; }
.footer-brand img { width: 250px; height: 100px; object-fit: contain; filter: invert(1) grayscale(1) brightness(2.6); mix-blend-mode: screen; }
.footer-brand p { margin: 8px 0 0; color: var(--blue-light); font-family: var(--serif); font-size: 1.15rem; }
.site-footer h2 { margin-bottom: 20px; color: #fff; font-family: var(--sans); font-size: .76rem; font-weight: 700; text-transform: uppercase; }
.site-footer > div:not(.footer-bottom) > a { display: block; width: fit-content; margin-bottom: 10px; color: #aebbc2; font-size: .82rem; }
.site-footer > div > a:hover { color: var(--blue-light); }
.site-footer > div > p { color: #9ba9b0; font-size: .83rem; }
.site-footer .text-link { color: var(--blue-light); }
.footer-bottom { grid-column: 1 / -1; margin-top: 34px; padding-top: 22px; display: flex; justify-content: space-between; color: #7f8d94; border-top: 1px solid #263137; font-size: .72rem; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .75s var(--ease), transform .75s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (max-width: 1100px) {
  :root { --header-h: 80px; }
  .site-header { grid-template-columns: 220px 1fr auto; gap: 24px; }
  .brand { width: 210px; }
  .brand img { width: 205px; }
  .primary-nav { gap: 24px; }
  .hero-content { width: 54vw; }
  .hero h1 { font-size: clamp(4rem, 7vw, 5.7rem); }
  .proof-band { margin-left: 24px; margin-right: 24px; }
  .proof-item { grid-template-columns: 54px 1fr; padding: 26px 22px; }
  .proof-item strong { font-size: 2.9rem; }
  .service-grid { grid-template-columns: repeat(2, 1fr); }
  .project-grid { grid-template-columns: 1.1fr 1fr; grid-template-rows: repeat(3, 260px); }
  .project-large { grid-row: span 2; }
  .project-tall { grid-row: span 2; }
  .project:nth-child(4), .project:nth-child(5) { grid-column: auto; }
  .process-list { grid-template-columns: repeat(2, 1fr); }
  .process-list li:nth-child(2) { border-right: 0; }
  .process-list li { border-bottom: 1px solid var(--line); }
  .contact-panel { margin-right: 32px; padding: 44px; }
  .site-footer { grid-template-columns: 1.2fr 1fr 1fr; }
  .site-footer > div:nth-child(4) { grid-column: span 3; }
}

@media (max-width: 820px) {
  :root { --header-h: 72px; }
  .site-header { padding: 0 18px; grid-template-columns: 1fr auto; }
  .brand { width: 190px; height: 64px; }
  .brand img { width: 185px; height: 68px; }
  .menu-toggle { width: 44px; height: 44px; display: grid; place-content: center; gap: 7px; border: 0; color: var(--ink); background: transparent; cursor: pointer; }
  .menu-toggle span:not(.sr-only) { width: 25px; height: 2px; background: currentColor; transition: transform .25s; }
  .menu-toggle[aria-expanded="true"] span:first-child { transform: translateY(4.5px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); }
  .primary-nav { position: fixed; inset: var(--header-h) 0 auto; padding: 30px 22px 38px; display: grid; gap: 0; background: #fff; border-bottom: 1px solid var(--line); transform: translateY(-120%); visibility: hidden; transition: transform .35s var(--ease), visibility .35s; }
  .primary-nav.is-open { transform: translateY(0); visibility: visible; }
  .primary-nav a { padding: 14px 0; border-bottom: 1px solid var(--line); font-family: var(--serif); font-size: 1.5rem; font-weight: 400; }
  .header-cta { display: none; }
  .hero { min-height: calc(100svh - var(--header-h) - 120px); align-items: flex-end; }
  .hero-media { object-position: 64% center; }
  .hero-fade { background: linear-gradient(180deg, rgba(255,255,255,.08) 18%, rgba(255,255,255,.72) 56%, #fff 86%); }
  .hero-content { width: auto; margin: 0; padding: 70px 22px 68px; }
  .hero h1 { max-width: 690px; font-size: clamp(3.45rem, 12vw, 5.4rem); }
  .hero p { max-width: 590px; }
  .scroll-cue { display: none; }
  .proof-band { margin: 0; grid-template-columns: 1fr; box-shadow: none; }
  .proof-item { min-height: 130px; border-right: 0; border-bottom: 1px solid var(--line); }
  .section { padding: 92px 22px; }
  .section-intro, .section-heading { grid-template-columns: 1fr; gap: 28px; margin-bottom: 42px; }
  .section-heading .text-link, .testimonials .section-heading > p { justify-self: start; }
  .section-intro h2, .section-heading h2 { font-size: clamp(3.3rem, 11vw, 4.7rem); }
  .service-grid { grid-template-columns: 1fr 1fr; }
  .service { min-height: 270px; }
  .section-dark { padding: 86px 22px; }
  .project-grid { grid-template-columns: 1fr 1fr; grid-template-rows: repeat(3, 230px); }
  .quote-grid { grid-template-columns: 1fr; }
  .quote-grid blockquote { min-height: 230px; border-right: 0; border-bottom: 1px solid var(--line); }
  .contact { grid-template-columns: 1fr; }
  .contact-media { min-height: 440px; }
  .contact-panel { margin: -62px 22px 44px; padding: 40px 28px; }
  .site-footer { grid-template-columns: 1fr 1fr; gap: 50px; }
  .site-footer > div:nth-child(4) { grid-column: span 2; }
}

@media (max-width: 560px) {
  .hero-content { padding-bottom: 42px; }
  .hero h1 { margin-bottom: 20px; font-size: clamp(3.15rem, 14vw, 4.25rem); line-height: .92; }
  .hero-actions { display: grid; grid-template-columns: 1fr; }
  .hero-actions .button { width: 100%; }
  .proof-item { grid-template-columns: 58px 1fr; }
  .section-intro h2, .section-heading h2, .contact h2 { font-size: clamp(3rem, 14vw, 4rem); }
  .service-grid { grid-template-columns: 1fr; }
  .service { min-height: 250px; }
  .project-grid { display: grid; grid-template-columns: 1fr; grid-template-rows: repeat(5, 310px); }
  .project-large, .project-tall { grid-row: auto; }
  .process-list { grid-template-columns: 1fr; }
  .process-list li, .process-list li:nth-child(2) { min-height: 220px; border-right: 0; }
  .process-list span { margin-bottom: 22px; }
  .quote-form-shell .ff-t-container { display: block; }
  .quote-form-shell .ff-btn-submit { width: 100%; }
  .contact-media { min-height: 340px; }
  .contact-panel { margin: -34px 14px 34px; padding: 34px 20px; }
  .site-footer { grid-template-columns: 1fr; gap: 34px; padding-top: 54px; }
  .site-footer > div:nth-child(4) { grid-column: auto; }
  .footer-bottom { align-items: flex-start; gap: 16px; }
  .whatsapp-float { right: 14px; bottom: max(14px, env(safe-area-inset-bottom)); width: 54px; min-height: 54px; padding: 0; justify-content: center; border-radius: 50%; }
  .whatsapp-float span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
  .reveal { opacity: 1; transform: none; }
}
