/* ==========================================================================
   FiberX — App Development (flagship service page). Uses the site's tokens
   from styles.css; every visual here is HTML/CSS/SVG, animated by appdev.js.
   ========================================================================== */
.ad-page { --ad-r: 22px; }

/* ---------- shared device frames ---------- */
.dv-phone { position: relative; width: 250px; aspect-ratio: 250 / 510; border-radius: 40px; padding: 10px;
  background: linear-gradient(145deg, #2a3142, #0d1018 40%, #1c2230); box-shadow: 0 0 0 1px rgba(255,255,255,.09), 0 40px 80px -30px rgba(0,0,0,.9), 0 0 60px -20px rgba(25,198,230,.35); }
.dv-phone .dv-screen { position: relative; height: 100%; border-radius: 31px; overflow: hidden; background: #070a12; }
.dv-notch { position: absolute; top: 18px; left: 50%; width: 76px; height: 20px; margin-left: -38px; border-radius: 12px; background: #000; z-index: 5; }
.dv-laptop { position: relative; width: 580px; }
.dv-lid { position: relative; aspect-ratio: 16 / 10.2; padding: 14px 14px 18px; border-radius: 18px 18px 6px 6px;
  background: linear-gradient(160deg, #2a3142, #0e1119 45%, #1b2130); box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 50px 90px -40px rgba(0,0,0,.95), 0 0 80px -30px rgba(124,77,255,.35); }
.dv-lid .dv-screen { height: 100%; border-radius: 8px; overflow: hidden; background: #070a12; }
.dv-cam { position: absolute; top: 5px; left: 50%; width: 5px; height: 5px; margin-left: -2.5px; border-radius: 50%; background: #1d2433; }
.dv-base { position: relative; height: 14px; margin: 0 -7%; border-radius: 2px 2px 14px 14px; background: linear-gradient(180deg, #3a4254, #151a25); box-shadow: 0 20px 40px -18px rgba(0,0,0,.9); }
.dv-base i { position: absolute; top: 0; left: 50%; width: 22%; height: 5px; margin-left: -11%; border-radius: 0 0 8px 8px; background: #0c0f16; }

/* ---------- generic app UI kit (inside the frames) ---------- */
.ui { position: absolute; inset: 0; font-family: var(--font-b); color: #e7ecf6; font-size: 11px; line-height: 1.35; }
.ui b { font-weight: 600; color: #fff; }
.ui small { color: #8d97ad; font-size: 9.5px; }
.ui-bar { display: flex; align-items: center; justify-content: space-between; padding: 42px 16px 10px; font: 600 14px/1.2 var(--font-d); color: #fff; }
.ui-bar em { font-style: normal; font-size: 8.5px; letter-spacing: .12em; color: var(--cyan); }
.ui-pill { font-size: 8px; letter-spacing: .14em; padding: 3px 7px; border-radius: 99px; border: 1px solid rgba(25,198,230,.35); color: var(--cyan-hi); }
.ui-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.ui-t { font: 600 13px/1 var(--font-d); color: #fff; }
.cta-b { margin: 12px 16px 0; padding: 10px 12px; border-radius: 12px; text-align: center; font-weight: 600; color: #04121a;
  background: linear-gradient(90deg, var(--cyan), var(--blue-hi)); box-shadow: 0 8px 22px -10px rgba(25,198,230,.8); }
.tag { justify-self: end; font: 600 8.5px/1 var(--font-m); letter-spacing: .06em; padding: 4px 7px; border-radius: 6px; }
.tag.ok { color: #62e3a9; background: rgba(15,169,104,.14); }
.tag.due { color: #ffb36b; background: rgba(255,106,0,.14); }

/* dashboard (hero laptop) */
.ui-dash { display: grid; grid-template-columns: 44px 1fr; }
.ui-side { display: grid; align-content: start; justify-items: center; gap: 14px; padding: 14px 0; background: rgba(255,255,255,.025); border-right: 1px solid rgba(255,255,255,.05); }
.ui-logo { width: 20px; height: 20px; border-radius: 7px; background: var(--grad-fiber); }
.ui-side i { width: 16px; height: 16px; border-radius: 5px; background: rgba(255,255,255,.08); }
.ui-side i.on { background: rgba(25,198,230,.4); }
.ui-main { padding: 14px 16px; min-width: 0; }
.ui-kpis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin-bottom: 12px; }
.ui-kpis.four { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.kpi { padding: 9px 10px; border-radius: 10px; background: rgba(255,255,255,.035); border: 1px solid rgba(255,255,255,.05); display: grid; gap: 3px; }
.kpi b { font: 600 17px/1 var(--font-d); }
.ui-list { display: grid; gap: 7px; }
.row { display: grid; grid-template-columns: 22px 1fr auto; align-items: center; gap: 10px; padding: 7px 9px; border-radius: 10px; background: rgba(255,255,255,.03); }
.row.new { background: rgba(25,198,230,.1); box-shadow: inset 0 0 0 1px rgba(25,198,230,.35); }
.av { width: 22px; height: 22px; border-radius: 50%; }
.av.a1 { background: linear-gradient(135deg, #2451E6, #19C6E6); } .av.a2 { background: linear-gradient(135deg, #7C4DFF, #A68BFF); }
.av.a3 { background: linear-gradient(135deg, #FF6A00, #F5B21B); } .av.a4 { background: linear-gradient(135deg, #0FA968, #19C6E6); }
.ln { display: grid; gap: 4px; } .ln i { height: 5px; border-radius: 3px; background: rgba(255,255,255,.14); } .ln i + i { background: rgba(255,255,255,.07); }

/* booking (hero phone) */
.ui-book .scr { position: absolute; inset: 0; opacity: 0; visibility: hidden; }
.ui-book .scr.is-on { opacity: 1; visibility: visible; }
.svc-row { display: grid; grid-template-columns: 10px 1fr; gap: 12px; align-items: center; margin: 8px 14px 0; padding: 12px; border-radius: 14px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.05); }
.svc-row span:last-child { display: grid; gap: 2px; } .svc-row b { font-size: 12px; }
.svc-row.sel { border-color: rgba(25,198,230,.6); background: rgba(25,198,230,.1); }
.dot { width: 10px; height: 10px; border-radius: 50%; } .dot.c1 { background: var(--cyan); } .dot.c2 { background: var(--violet-hi); } .dot.c3 { background: var(--orange); }
.days { display: grid; grid-template-columns: repeat(4, 1fr); gap: 6px; margin: 4px 14px 12px; }
.days i { display: grid; justify-items: center; gap: 2px; padding: 8px 0; border-radius: 12px; font-style: normal; font-size: 9px; color: #8d97ad; background: rgba(255,255,255,.035); }
.days i b { font-size: 14px; } .days i.on { background: rgba(25,198,230,.16); color: var(--cyan-hi); box-shadow: inset 0 0 0 1px rgba(25,198,230,.5); }
.slots { display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; margin: 0 14px; }
.slots i { padding: 9px 0; border-radius: 10px; text-align: center; font-style: normal; font: 500 10.5px/1 var(--font-m); background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.06); }
.slots i.off { opacity: .35; text-decoration: line-through; } .slots i.sel { background: var(--cyan); color: #04121a; border-color: transparent; }
.s3 { display: grid; align-content: center; justify-items: center; gap: 8px; text-align: center; padding: 0 20px; }
.check { width: 64px; height: 64px; fill: none; stroke: var(--cyan); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; filter: drop-shadow(0 0 10px rgba(25,198,230,.6)); }
.check circle { stroke-dasharray: 145; stroke-dashoffset: 0; opacity: .5; } .check path { stroke-dasharray: 40; stroke-dashoffset: 0; }
.done-t { font: 600 17px/1.1 var(--font-d); } .done-s { font-size: 10.5px; }
.rem { display: flex; gap: 7px; align-items: center; margin-top: 8px; padding: 8px 10px; border-radius: 10px; background: rgba(255,255,255,.04); font-size: 10px; color: #b8c1d4; }
.rem i { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px var(--green); }
.tap { position: absolute; width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%; border: 2px solid rgba(255,255,255,.85); background: rgba(255,255,255,.18); opacity: 0; pointer-events: none; z-index: 6; }

/* ---------- 1. hero ---------- */
.ad-hero { position: relative; overflow: hidden; isolation: isolate; padding: clamp(40px, 7vh, 90px) 0 clamp(40px, 6vh, 80px); }
.ad-hero .hero-bg { position: absolute; inset: 0; z-index: 0; }
.ad-hero .fiber-canvas { position: absolute; inset: 0; opacity: .75; }
.ad-hero-in { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.05fr); gap: clamp(24px, 4vw, 64px); align-items: center; min-height: min(78vh, 760px); }
.ad-hero-copy { display: grid; justify-items: start; gap: 18px; }
.ad-hero-copy h1 { font-size: clamp(2.2rem, 1.2rem + 3.4vw, 4.1rem); line-height: 1.02; letter-spacing: -.025em; max-width: 14ch; }
.ad-hero-copy .lead { max-width: 54ch; }
.ad-stage { position: relative; height: clamp(380px, 56vh, 560px); perspective: 1600px; }
.ad-rig { position: absolute; inset: 0; transform-style: preserve-3d; will-change: transform; }
.ad-hero-laptop { position: absolute; right: 0; top: 4%; width: min(92%, 580px); transform: translateZ(-60px) rotateY(-14deg) rotateX(4deg); transform-origin: 70% 50%; }
.ad-hero-phone { position: absolute; left: 4%; bottom: 0; width: min(38%, 236px); transform: translateZ(90px) rotateY(12deg) rotateX(2deg); }
@media (max-width: 1180px) { .ad-hero-phone { left: 0; } }

/* ---------- 2. switcher ---------- */
.ad-switch .sec-head { margin-bottom: 26px; }
.sw-tabs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 28px; }
.sw-tabs [role=tab] { padding: 10px 16px; border-radius: var(--r-pill); border: 1px solid var(--line-2); background: rgba(255,255,255,.03); color: var(--text-2); font: 500 .9rem/1 var(--font-b); cursor: pointer; transition: color var(--dur), background var(--dur), border-color var(--dur); }
.sw-tabs [role=tab]:hover { color: var(--white); border-color: var(--line-3); }
.sw-tabs [role=tab][aria-selected=true] { color: #04121a; background: var(--white); border-color: var(--white); }
.sw-tabs [role=tab]:focus-visible { outline: 2px solid var(--cyan); outline-offset: 3px; }
.sw-body { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); gap: clamp(24px, 4vw, 60px); align-items: center; }
.sw-device { position: relative; height: 470px; display: grid; place-items: center; perspective: 1400px; }
.sw-frame { position: relative; width: 600px; height: 380px; border-radius: 18px; padding: 34px 12px 12px; background: linear-gradient(160deg, #262d3d, #0e1119 45%, #1b2130);
  box-shadow: 0 0 0 1px rgba(255,255,255,.08), 0 50px 90px -40px rgba(0,0,0,.95), 0 0 90px -40px rgba(25,198,230,.45); transform: rotateX(6deg) rotateY(-8deg); }
.sw-chrome { position: absolute; top: 11px; left: 16px; right: 16px; display: flex; align-items: center; gap: 6px; }
.sw-chrome i { width: 9px; height: 9px; border-radius: 50%; background: #394157; } .sw-chrome i:first-child { background: #e0554d; } .sw-chrome i:nth-child(2) { background: #e8b33f; } .sw-chrome i:nth-child(3) { background: #35c878; }
.sw-url { margin-left: 12px; padding: 3px 12px; border-radius: 99px; background: rgba(255,255,255,.05); font-size: 9.5px; color: var(--muted); }
.sw-notch { position: absolute; top: 16px; left: 50%; width: 70px; height: 18px; margin-left: -35px; border-radius: 10px; background: #000; opacity: 0; z-index: 3; }
.sw-frame.is-phone .sw-notch { opacity: 1; } .sw-frame.is-phone .sw-chrome { opacity: 0; }
.sw-screen { position: relative; height: 100%; border-radius: 9px; overflow: hidden; background: #070a12; }
.sw-s { padding: 16px; opacity: 0; visibility: hidden; }
.sw-s.is-on { opacity: 1; visibility: visible; }
.is-phone .sw-s .ui-bar { padding-top: 34px; }
.sw-s[data-s=mobile], .sw-s[data-s=book], .sw-s[data-s=ai] { padding: 0 0 16px; }
.job { position: relative; display: grid; gap: 3px; margin: 8px 14px 0; padding: 12px 12px 12px 14px; border-radius: 14px; background: rgba(255,255,255,.04); border-left: 3px solid rgba(255,255,255,.12); }
.job .st { justify-self: start; font: 600 8px/1 var(--font-m); letter-spacing: .1em; text-transform: uppercase; color: #8d97ad; }
.job .st.on { color: var(--cyan-hi); } .job.done { border-left-color: var(--green); } .job.done .st { color: #62e3a9; }
.job:first-of-type { border-left-color: var(--cyan); }
.tabbar { position: absolute; left: 14px; right: 14px; bottom: 14px; display: flex; justify-content: space-around; padding: 11px; border-radius: 16px; background: rgba(255,255,255,.05); }
.tabbar i { width: 16px; height: 16px; border-radius: 5px; background: rgba(255,255,255,.12); } .tabbar i.on { background: var(--cyan); }
.steps { display: flex; gap: 6px; margin-bottom: 14px; }
.steps i { flex: 1; padding-top: 7px; border-top: 3px solid rgba(255,255,255,.1); font-style: normal; font-size: 9.5px; color: #8d97ad; }
.steps i.on { border-color: var(--cyan); color: var(--cyan-hi); }
.field { display: grid; gap: 5px; margin-bottom: 10px; } .field.two { grid-template-columns: 1fr 1fr; gap: 10px; } .field.two > span { display: grid; gap: 5px; }
.in { display: block; min-height: 30px; padding: 8px 10px; border-radius: 9px; background: rgba(255,255,255,.04); border: 1px solid rgba(255,255,255,.08); font-size: 11px; color: #fff; }
.in.caret::after { content: ""; display: inline-block; width: 1px; height: 12px; margin-left: 1px; background: var(--cyan); vertical-align: -2px; animation: blink 1s steps(1) infinite; }
@keyframes blink { 50% { opacity: 0; } }
.sw-s[data-s=web] .cta-b { margin: 16px 0 0; }
.charts { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; height: 170px; }
.bars { display: flex; align-items: flex-end; gap: 5px; padding: 12px; border-radius: 12px; background: rgba(255,255,255,.03); }
.bars i { flex: 1; height: var(--h); border-radius: 4px 4px 1px 1px; background: linear-gradient(180deg, var(--cyan), rgba(36,81,230,.5)); transform-origin: bottom; }
.line { width: 100%; height: 100%; border-radius: 12px; background: rgba(255,255,255,.03); }
.line .stroke { fill: none; stroke: var(--violet-hi); stroke-width: 2.2; vector-effect: non-scaling-stroke; }
.line .area { fill: rgba(124,77,255,.14); }
.inv { display: grid; grid-template-columns: 1fr 1fr 1fr 44px; align-items: center; gap: 8px; padding: 9px 10px; border-radius: 10px; font-size: 11px; }
.inv:not(.head) { background: rgba(255,255,255,.03); margin-bottom: 6px; } .inv.head { font-size: 8.5px; letter-spacing: .12em; color: #6e7891; padding-bottom: 4px; }
.inv .tag { justify-self: start; } .dl { justify-self: end; font: 600 8.5px/1 var(--font-m); color: var(--cyan-hi); }
.sw-s[data-s=portal] .cta-b { margin: 10px 0 0; }
.wk { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; margin: 0 14px; }
.wk .col { display: grid; gap: 5px; } .wk .col > span { text-align: center; font: 500 8.5px/1 var(--font-m); color: #8d97ad; padding-bottom: 3px; }
.wk .c { height: 26px; border-radius: 7px; background: rgba(255,255,255,.04); } .wk .c.b { background: rgba(124,77,255,.35); } .wk .c.f { background: rgba(25,198,230,.55); box-shadow: 0 0 12px rgba(25,198,230,.5); }
.chat { display: grid; gap: 8px; padding: 6px 14px; }
.msg { max-width: 82%; padding: 9px 11px; border-radius: 14px; font-size: 11px; line-height: 1.4; }
.msg.me { justify-self: end; background: var(--blue); color: #fff; border-bottom-right-radius: 4px; }
.msg.bot { justify-self: start; background: rgba(255,255,255,.06); border-bottom-left-radius: 4px; }
.dots { display: inline-flex; gap: 3px; } .dots i { width: 5px; height: 5px; border-radius: 50%; background: #8d97ad; animation: dotb 1s ease-in-out infinite; }
.dots i:nth-child(2) { animation-delay: .15s; } .dots i:nth-child(3) { animation-delay: .3s; }
@keyframes dotb { 0%, 80%, 100% { opacity: .3; transform: translateY(0); } 40% { opacity: 1; transform: translateY(-2px); } }
.chips-row { display: flex; gap: 6px; padding: 6px 14px; } .chips-row i { font-style: normal; font-size: 10px; padding: 6px 9px; border-radius: 99px; border: 1px solid rgba(25,198,230,.4); color: var(--cyan-hi); }
.sw-panels { position: relative; min-height: 260px; }
.sw-p { display: grid; gap: 14px; } .sw-p h3 { font-size: var(--fs-h3); }
.sw-p p { color: var(--text-2); line-height: 1.65; }
.sw-p ul { display: grid; gap: 10px; padding: 0; list-style: none; }
.sw-p li { position: relative; padding-left: 26px; color: var(--text-2); line-height: 1.5; }
.sw-p li::before { content: ""; position: absolute; left: 2px; top: .45em; width: 12px; height: 7px; border-left: 2px solid var(--cyan); border-bottom: 2px solid var(--cyan); transform: rotate(-45deg); }
.sw-p a, .ai-more a { color: var(--cyan); }

/* ---------- phones & tablets ---------- */
@media (max-width: 980px) {
  .ad-hero-in { grid-template-columns: 1fr; min-height: 0; }
  .ad-stage { height: 440px; max-width: 560px; width: 100%; justify-self: center; }
  .ad-hero-laptop { width: 88%; right: -4%; top: 2%; }
  .ad-hero-phone { width: 190px; left: 0; }
  .sw-body { grid-template-columns: 1fr; }
  .sw-tabs { flex-wrap: nowrap; overflow-x: auto; scroll-snap-type: x mandatory; margin-inline: calc(var(--gutter) * -1); padding: 2px var(--gutter) 8px; scrollbar-width: none; }
  .sw-tabs::-webkit-scrollbar { display: none; }
  .sw-tabs [role=tab] { flex: 0 0 auto; scroll-snap-align: start; }
  .sw-device { height: 440px; }
}
@media (max-width: 560px) {
  .ad-stage { height: 350px; }
  .ad-hero-laptop { width: 96%; right: -10%; }
  .ad-hero-phone { width: 150px; }
  .sw-device { height: 440px; }
}
@media (prefers-reduced-motion: reduce) {
  .dots i, .in.caret::after { animation: none; }
  .ai-chat .msg { animation: none; }
}

/* ---------- stock video (approved Pexels clips, graded; posters until near the viewport) ---------- */
.lazyv { display: block; width: 100%; height: 100%; object-fit: cover; background: var(--bg-2); }
.ad-reel { position: absolute; inset: 0 0 0 30%; opacity: .5;
  -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 38%, #000 80%, transparent 100%), linear-gradient(180deg, transparent, #000 18%, #000 78%, transparent);
  -webkit-mask-composite: source-in; mask-image: linear-gradient(90deg, transparent 0%, #000 38%, #000 80%, transparent 100%), linear-gradient(180deg, transparent, #000 18%, #000 78%, transparent); mask-composite: intersect; }
.ad-reel::after { content: ""; position: absolute; inset: 0; background: linear-gradient(120deg, rgba(5,6,11,.55), rgba(36,81,230,.18) 50%, rgba(124,77,255,.22)); mix-blend-mode: multiply; }
@media (max-width: 980px) {
  .ad-reel { inset: 0; opacity: .32; -webkit-mask-image: linear-gradient(180deg, transparent, #000 25%, #000 70%, transparent); mask-image: linear-gradient(180deg, transparent, #000 25%, #000 70%, transparent); }
}

/* ---------- process: five steps, each with its clip ---------- */
.st-list { display: grid; gap: 18px; margin: 34px 0 0; padding: 0; list-style: none; }
.st-item { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(20px, 3.5vw, 56px); align-items: center; }
.st-item:nth-child(even) .st-media { order: 2; }
.st-media { position: relative; margin: 0; aspect-ratio: 16 / 9; border-radius: var(--ad-r); overflow: hidden; border: 1px solid var(--line); background: var(--bg-2); box-shadow: 0 30px 70px -40px rgba(0,0,0,.9); }
.st-media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 50%, rgba(5,6,11,.7)), linear-gradient(120deg, rgba(36,81,230,.14), rgba(124,77,255,.16)); pointer-events: none; }
.st-num { position: absolute; left: 16px; bottom: 12px; z-index: 1; font-size: .8rem; letter-spacing: .14em; color: var(--cyan); }
.st-copy { display: grid; gap: 10px; max-width: 46ch; }
.st-copy h3 { font-size: var(--fs-h3); }
.st-copy p { color: var(--text-2); line-height: 1.65; }
/* ---------- integrations row ---------- */
.int-row { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; margin: 30px 0 0; padding: 0; list-style: none; }
.int-row li { display: grid; justify-items: start; gap: 8px; padding: 18px 16px; border-radius: 18px; border: 1px solid var(--line); background: rgba(255,255,255,.025); }
.int-row .ic { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 14px; background: var(--surface-2); border: 1px solid var(--line-2); color: var(--cyan-hi); }
.int-row .ic svg { width: 22px; height: 22px; }
.int-row b { color: var(--white); font: 600 1rem/1.2 var(--font-d); } .int-row small { color: var(--text-2); font-size: .85rem; line-height: 1.45; }
.int-fine { margin-top: 14px; font-size: .68rem; letter-spacing: .08em; color: var(--muted); }
@media (max-width: 980px) {
  .st-item { grid-template-columns: 1fr; gap: 14px; } .st-item:nth-child(even) .st-media { order: 0; }
  .st-media { aspect-ratio: 16 / 10; }
  .int-row { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
