/* ============================================================
   UxiTech — iPad Repair (ipad.uxitech.com)
   Mobile-first. System fonts for instant load.
   ============================================================ */

:root {
  --navy:        #0B2545;   /* brand anchor / trust */
  --navy-deep:   #081B34;   /* darker sections */
  --blue:        #145DA0;   /* interactive blue */
  --blue-dark:   #0F4C86;
  --amber:       #F28C1B;   /* CTA / energy accent */
  --amber-dark:  #DB7A0C;
  --ink:         #16202E;   /* body text */
  --slate:       #5B6B7C;   /* muted text */
  --line:        #E2E8F0;   /* borders */
  --surface:     #F6F8FB;   /* light section bg */
  --white:       #FFFFFF;
  --success:     #1B7A43;
  --danger:      #C0392B;

  --radius:      14px;
  --radius-sm:   9px;
  --shadow:      0 6px 22px rgba(11, 37, 69, 0.08);
  --shadow-lg:   0 18px 44px rgba(11, 37, 69, 0.14);
  --wrap:        1120px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }

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

body {
  font-family: var(--font);
  color: var(--ink);
  background: var(--white);
  line-height: 1.6;
  overflow-x: hidden;
}

img, svg { max-width: 100%; display: block; }

a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3, h4 { line-height: 1.15; color: var(--navy); letter-spacing: -0.02em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
.wrap-narrow { max-width: 760px; }
.center { text-align: center; }

/* Accessibility */
.skip-link {
  position: absolute; left: -9999px; top: 0;
  background: var(--navy); color: #fff; padding: 10px 16px; border-radius: 0 0 8px 0; z-index: 2000;
}
.skip-link:focus { left: 0; }

:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; border-radius: 4px; }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 700; font-size: 1rem; line-height: 1;
  padding: 13px 22px; border-radius: var(--radius-sm);
  border: 2px solid transparent; cursor: pointer;
  transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
  text-decoration: none; white-space: nowrap;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn-sm { padding: 9px 15px; font-size: .92rem; }
.btn-lg { padding: 16px 30px; font-size: 1.06rem; }
.btn-block { width: 100%; }

.btn-primary { background: var(--amber); color: var(--navy); box-shadow: 0 4px 12px rgba(242,140,27,.28); }
.btn-primary:hover { background: var(--amber-dark); }

.btn-accent { background: var(--amber); color: var(--navy); }
.btn-accent:hover { background: var(--amber-dark); }

.btn-call { background: var(--white); color: var(--navy); border-color: var(--line); }
.btn-call:hover { border-color: var(--blue); color: var(--blue); }

.btn-ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.55); }
.btn-ghost:hover { background: rgba(255,255,255,.12); }

/* ============================================================
   HEADER
   ============================================================ */
.site-header {
  position: sticky; top: 0; z-index: 1000;
  background: rgba(255,255,255,.96);
  backdrop-filter: saturate(180%) blur(6px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; gap: 16px; padding-top: 12px; padding-bottom: 12px; }

.brand { display: flex; align-items: center; gap: 10px; color: var(--navy); }
.brand:hover { text-decoration: none; }
.brand-mark { display: inline-flex; }
.brand-text { display: flex; flex-direction: column; line-height: 1; }
.brand-text strong { font-size: 1.22rem; letter-spacing: -0.02em; }
.brand-sub { font-size: .72rem; color: var(--amber-dark); font-weight: 700; text-transform: uppercase; letter-spacing: .08em; margin-top: 2px; }

.nav { margin-left: auto; }
.nav-links { display: flex; gap: 22px; list-style: none; }
.nav-links a { color: var(--ink); font-weight: 600; font-size: .96rem; }
.nav-links a:hover { color: var(--blue); text-decoration: none; }

.header-actions { display: flex; align-items: center; gap: 10px; }

.menu-toggle {
  display: none; flex-direction: column; justify-content: space-between;
  width: 30px; height: 22px; background: none; border: none; cursor: pointer; padding: 2px;
}
.menu-toggle span { height: 3px; width: 100%; background: var(--navy); border-radius: 3px; transition: .25s; }
.menu-toggle.active span:nth-child(1) { transform: translateY(9.5px) rotate(45deg); }
.menu-toggle.active span:nth-child(2) { opacity: 0; }
.menu-toggle.active span:nth-child(3) { transform: translateY(-9.5px) rotate(-45deg); }

/* ============================================================
   HERO
   ============================================================ */
.hero {
  background:
    radial-gradient(1100px 460px at 78% -8%, rgba(20,93,160,.18), transparent 60%),
    linear-gradient(160deg, var(--navy) 0%, var(--navy-deep) 100%);
  color: #EAF1FA;
  padding: 60px 0 68px;
}
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
.eyebrow {
  display: inline-block; font-size: .8rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--amber); margin-bottom: 14px;
}
.hero h1 { color: #fff; font-size: 2.3rem; margin-bottom: 16px; }
.hero-lead { font-size: 1.1rem; color: #C7D6E8; max-width: 560px; margin-bottom: 26px; }

.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.cta-row.center { justify-content: center; }

.hero-trust { list-style: none; display: flex; flex-wrap: wrap; gap: 8px 20px; margin-top: 26px; }
.hero-trust li { position: relative; padding-left: 22px; font-size: .92rem; color: #BFD1E6; }
.hero-trust li::before {
  content: ""; position: absolute; left: 0; top: 6px; width: 12px; height: 8px;
  border-left: 2px solid var(--amber); border-bottom: 2px solid var(--amber);
  transform: rotate(-45deg);
}

/* Hero device (signature) */
.hero-art { display: flex; justify-content: center; }
.device {
  position: relative; width: 230px; height: 300px; background: #0E2C4F;
  border: 3px solid #1B4570; border-radius: 26px; padding: 16px;
  box-shadow: var(--shadow-lg); display: flex;
}
.device-screen {
  position: relative; flex: 1; border-radius: 12px; overflow: hidden;
  background: linear-gradient(135deg, #12365f, #0c294a);
  display: flex; align-items: center; justify-content: center;
}
.device-btn { position: absolute; bottom: -3px; left: 50%; transform: translateX(-50%); width: 34px; height: 4px; background:#1B4570; border-radius: 3px; }
.crack {
  position: absolute; inset: 0;
  background:
    linear-gradient(58deg, transparent 48%, rgba(255,255,255,.5) 49%, transparent 50%),
    linear-gradient(120deg, transparent 55%, rgba(255,255,255,.35) 56%, transparent 57%),
    linear-gradient(30deg, transparent 62%, rgba(255,255,255,.3) 63%, transparent 64%);
  animation: crackFade 4.5s ease-in-out infinite;
}
.device-heal { text-align: center; opacity: 0; animation: healShow 4.5s ease-in-out infinite; }
.device-heal svg { margin: 0 auto 8px; }
.device-heal p { color: #EAF1FA; font-weight: 700; font-size: .92rem; }
@keyframes crackFade { 0%,40% { opacity: 1; } 60%,100% { opacity: 0; } }
@keyframes healShow  { 0%,45% { opacity: 0; } 65%,95% { opacity: 1; } 100% { opacity: 0; } }

/* ============================================================
   QUOTE FORM
   ============================================================ */
.quote-section { background: var(--surface); padding: 0; }
.quote-card {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: var(--shadow-lg); margin: -44px auto 56px; padding: 30px;
  max-width: 860px; position: relative;
}
.quote-intro { margin-bottom: 22px; }
.quote-intro h2 { font-size: 1.6rem; margin-bottom: 6px; }
.quote-intro p { color: var(--slate); }
.quote-or {
  display: flex; align-items: center; flex-wrap: wrap; gap: 10px; margin-top: 14px;
  padding-top: 16px; border-top: 1px dashed var(--line); font-size: .95rem; color: var(--slate);
}

.quote-form .field { margin-bottom: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: 6px; color: var(--ink); }
.req { color: var(--danger); }
.optional { color: var(--slate); font-weight: 500; }

input, select, textarea {
  width: 100%; font-family: var(--font); font-size: 1rem; color: var(--ink);
  padding: 12px 13px; border: 1.5px solid var(--line); border-radius: var(--radius-sm);
  background: var(--white); transition: border-color .15s, box-shadow .15s;
}
input::placeholder, textarea::placeholder { color: #9AA8B6; }
input:focus, select:focus, textarea:focus {
  outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px rgba(20,93,160,.15);
}
textarea { resize: vertical; }
select { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%235B6B7C' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; background-size: 18px; padding-right: 38px; }

input.invalid, select.invalid, textarea.invalid { border-color: var(--danger); }
.error { color: var(--danger); font-size: .82rem; margin-top: 5px; min-height: 1px; }

.consent-field { margin-top: 4px; }
.consent { display: flex; align-items: flex-start; gap: 10px; font-weight: 500; font-size: .9rem; color: var(--slate); cursor: pointer; }
.consent input { width: 18px; height: 18px; margin-top: 3px; flex: 0 0 auto; accent-color: var(--blue); }
.consent.invalid { color: var(--danger); }

.form-note { font-size: .82rem; color: var(--slate); text-align: center; margin-top: 14px; }

.form-success, .form-fail {
  display: flex; gap: 12px; align-items: flex-start; margin-top: 18px;
  padding: 16px; border-radius: var(--radius-sm);
}
.form-success { background: #EAF7EF; border: 1px solid #BEE3CC; }
.form-success div { display: flex; flex-direction: column; }
.form-success strong { color: var(--success); }
.form-success span { color: #3B6B4E; font-size: .9rem; }
.form-fail { background: #FCECEA; border: 1px solid #F3C6C0; color: var(--danger); font-size: .92rem; }

/* ============================================================
   SECTIONS
   ============================================================ */
.section { padding: 66px 0; }
.section-alt { background: var(--surface); }
.section-eyebrow {
  text-align: center; font-size: .8rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  color: var(--amber-dark); margin-bottom: 10px;
}
.section-title { text-align: center; font-size: 1.85rem; margin-bottom: 40px; }

.grid { display: grid; gap: 20px; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

/* Problem tiles */
.tile {
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 24px; box-shadow: var(--shadow); transition: transform .18s, box-shadow .18s;
}
.tile:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.tile-icon { color: var(--navy); width: 50px; height: 50px; border-radius: 12px; background: #EAF1FA; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.tile h3 { font-size: 1.12rem; margin-bottom: 6px; }
.tile p { color: var(--slate); font-size: .95rem; }
#problems .center { margin-top: 36px; }

/* Services */
.services-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; align-items: start; }
.service-feature {
  background: linear-gradient(160deg, var(--navy), var(--navy-deep)); color: #EAF1FA;
  border-radius: var(--radius); padding: 30px; box-shadow: var(--shadow-lg);
}
.feature-tag { display: inline-block; background: var(--amber); color: var(--navy); font-weight: 700; font-size: .72rem; letter-spacing: .06em; text-transform: uppercase; padding: 5px 10px; border-radius: 30px; margin-bottom: 14px; }
.service-feature h3 { color: #fff; font-size: 1.5rem; margin-bottom: 10px; }
.service-feature p { color: #C7D6E8; margin-bottom: 22px; }
.service-list { list-style: none; display: grid; gap: 4px; }
.service-list li { display: flex; gap: 14px; align-items: flex-start; padding: 15px 8px; border-bottom: 1px solid var(--line); }
.service-list li:last-child { border-bottom: none; }
.service-list .dot { flex: 0 0 auto; width: 10px; height: 10px; border-radius: 50%; background: var(--amber); margin-top: 7px; }
.service-list strong { color: var(--navy); font-size: 1.02rem; }
.service-list p { color: var(--slate); font-size: .92rem; margin-top: 2px; }

/* Why cards */
.why-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow); }
.why-icon { color: var(--navy); width: 46px; height: 46px; border-radius: 11px; background: #EAF1FA; display: flex; align-items: center; justify-content: center; margin-bottom: 14px; }
.why-card h3 { font-size: 1.08rem; margin-bottom: 6px; }
.why-card p { color: var(--slate); font-size: .93rem; }

/* Steps */
.steps { list-style: none; display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; margin-bottom: 36px; counter-reset: step; }
.steps li { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px 22px; box-shadow: var(--shadow); position: relative; }
.step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; border-radius: 50%; background: var(--amber); color: var(--navy);
  font-weight: 800; font-size: 1.15rem; margin-bottom: 14px;
}
.steps h3 { font-size: 1.1rem; margin-bottom: 6px; }
.steps p { color: var(--slate); font-size: .93rem; }

/* FAQ */
.faq { border-top: 1px solid var(--line); }
.faq-item { border-bottom: 1px solid var(--line); }
.faq-q {
  width: 100%; background: none; border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 20px 4px; font-size: 1.05rem; font-weight: 600; color: var(--navy); text-align: left; font-family: var(--font);
}
.faq-icon { flex: 0 0 auto; position: relative; width: 18px; height: 18px; }
.faq-icon::before, .faq-icon::after { content: ""; position: absolute; background: var(--amber-dark); border-radius: 2px; transition: transform .2s; }
.faq-icon::before { top: 8px; left: 0; width: 18px; height: 2.5px; }
.faq-icon::after { left: 8px; top: 0; width: 2.5px; height: 18px; }
.faq-q[aria-expanded="true"] .faq-icon::after { transform: scaleY(0); }
.faq-a { max-height: 0; overflow: hidden; transition: max-height .28s ease; }
.faq-a p { padding: 0 4px 20px; color: var(--slate); }

/* Service area */
.area-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 34px; align-items: start; }
.area-copy .section-eyebrow, .area-copy .section-title { text-align: left; }
.area-copy .section-title { margin-bottom: 16px; }
.area-copy > p { color: var(--slate); margin-bottom: 16px; }
.area-list { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 16px; }
.area-list li { position: relative; padding-left: 20px; color: var(--ink); font-weight: 600; }
.area-list li::before { content: ""; position: absolute; left: 0; top: 8px; width: 8px; height: 8px; border-radius: 50%; background: var(--amber); }
.area-card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); padding: 26px; box-shadow: var(--shadow-lg); }
.area-card h3 { font-size: 1.2rem; margin-bottom: 12px; }
.area-address { font-weight: 700; color: var(--navy); font-size: 1.08rem; margin-bottom: 8px; }
.area-meta { color: var(--slate); font-size: .92rem; margin-bottom: 20px; }
.area-cta { display: grid; gap: 10px; }

/* Final CTA */
.final-cta { background: linear-gradient(160deg, var(--navy), var(--navy-deep)); color: #EAF1FA; padding: 64px 0; text-align: center; }
.final-cta h2 { color: #fff; font-size: 1.9rem; margin-bottom: 10px; }
.final-cta p { color: #C7D6E8; margin-bottom: 26px; }

/* ============================================================
   FOOTER
   ============================================================ */
.site-footer { background: var(--navy-deep); color: #9FB4CC; padding: 52px 0 28px; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 30px; }
.site-footer .brand-text strong { color: #fff; font-size: 1.2rem; }
.site-footer .brand-sub { color: var(--amber); }
.footer-brand p { margin-top: 10px; max-width: 320px; font-size: .93rem; }
.footer-col h4 { color: #fff; font-size: .95rem; margin-bottom: 12px; text-transform: uppercase; letter-spacing: .06em; }
.footer-col p { font-size: .93rem; margin-bottom: 8px; }
.footer-col a { color: #BFD1E6; }
.footer-col a:hover { color: #fff; }
.footer-legal { margin-top: 32px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.12); }
.footer-legal p { font-size: .82rem; color: #7F97B2; margin-bottom: 8px; }
.legal-fine { font-size: .78rem; line-height: 1.6; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .5s ease, transform .5s ease; }
.reveal.in { opacity: 1; transform: none; }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (min-width: 861px) {
  .hero-grid { grid-template-columns: 1.15fr .85fr; }
  .hero h1 { font-size: 2.9rem; }
}

@media (max-width: 860px) {
  .nav, .nav-quote { display: none; }
  .menu-toggle { display: flex; }
  .header-inner { flex-wrap: nowrap; }
  .header-actions { margin-left: auto; }

  .nav.open {
    display: block; position: absolute; top: 100%; left: 0; right: 0;
    background: #fff; border-bottom: 1px solid var(--line); box-shadow: var(--shadow); padding: 8px 20px 16px;
  }
  .nav.open .nav-links { flex-direction: column; gap: 0; }
  .nav.open .nav-links li { border-bottom: 1px solid var(--line); }
  .nav.open .nav-links li:last-child { border-bottom: none; }
  .nav.open .nav-links a { display: block; padding: 14px 4px; }

  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
  .services-layout { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr 1fr; }
  .area-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .hero { padding: 44px 0 54px; }
  .hero h1 { font-size: 2rem; }
  .hero-lead { font-size: 1.02rem; }
  .cta-row .btn { flex: 1 1 auto; }
  .btn-call-label { display: none; }
  .header-actions .btn-call { padding: 9px 12px; }

  .quote-card { padding: 22px 18px; margin-top: -34px; }
  .quote-intro h2 { font-size: 1.4rem; }
  .field-row { grid-template-columns: 1fr; gap: 0; }

  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .area-list { grid-template-columns: 1fr; }
  .section { padding: 50px 0; }
  .section-title { font-size: 1.55rem; }
}

/* Respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; scroll-behavior: auto !important; }
  .reveal { opacity: 1; transform: none; transition: none; }
  .btn:hover { transform: none; }
}
