/* KTL Tech Hub – 3D redesign (original). Navy + orange. */
:root {
  --navy: #0B1E3A;
  --navy-deep: #061428;
  --navy-mid: #123056;
  --orange: #FF6B00;
  --orange-soft: rgba(255, 107, 0, 0.14);
  --orange-glow: rgba(255, 107, 0, 0.45);
  --white: #ffffff;
  --muted: #8a9bb0;
  --text: #d6e0ec;
  --text-strong: #f4f7fb;
  --glass: rgba(255, 255, 255, 0.06);
  --glass-border: rgba(255, 255, 255, 0.12);
  --border: rgba(226, 232, 240, 0.12);
  --max: 1100px;
  --header-h: 68px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

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

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  color: var(--text-strong);
  background: var(--navy-deep);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

a { color: var(--orange); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }

.container {
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.35rem;
  position: relative;
  z-index: 2;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  height: var(--header-h);
  display: flex;
  align-items: center;
  background: rgba(6, 20, 40, 0.72);
  backdrop-filter: blur(16px) saturate(140%);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  border-bottom: 1px solid var(--glass-border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  width: 100%;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 1.35rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: var(--white);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.01em;
}
.brand:hover { text-decoration: none; opacity: 0.95; }
.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  object-fit: contain;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem;
  padding: 0.3rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.1);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}
.nav a {
  color: rgba(255, 255, 255, 0.78);
  font-size: 0.92rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  border-radius: 999px;
  transition: color 0.2s, background 0.2s;
}
.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--white);
  background: var(--orange-soft);
  text-decoration: none;
}
.nav a[aria-current="page"] { color: var(--orange); }

main { flex: 1; position: relative; }

/* ——— Hero with 3D canvas ——— */
.hero {
  position: relative;
  min-height: clamp(520px, 88vh, 820px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3.5rem 0 4rem;
  overflow: hidden;
  background: radial-gradient(ellipse 70% 55% at 72% 42%, rgba(255, 107, 0, 0.2), transparent 58%),
              radial-gradient(ellipse 50% 45% at 18% 78%, rgba(18, 48, 86, 0.95), transparent 52%),
              linear-gradient(165deg, #050f1e 0%, #0B1E3A 48%, #091628 100%);
}

.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.hero-fallback {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}
.hero-fallback .orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(40px);
  opacity: 0.55;
  animation: drift 14s var(--ease) infinite alternate;
}
.hero-fallback .orb-a {
  width: 280px; height: 280px;
  background: rgba(255, 107, 0, 0.35);
  top: 18%; right: 12%;
}
.hero-fallback .orb-b {
  width: 220px; height: 220px;
  background: rgba(40, 100, 180, 0.4);
  bottom: 15%; left: 10%;
  animation-delay: -4s;
}
.hero-fallback .orb-c {
  width: 140px; height: 140px;
  background: rgba(255, 160, 60, 0.25);
  top: 55%; right: 35%;
  animation-delay: -7s;
}

@keyframes drift {
  from { transform: translate3d(0, 0, 0) scale(1); }
  to { transform: translate3d(-30px, 24px, 0) scale(1.08); }
}

.hero-grid {
  position: absolute;
  inset: 0;
  z-index: 1;
  background-image:
    linear-gradient(rgba(255,255,255,0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.03) 1px, transparent 1px);
  background-size: 56px 56px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, black, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse 70% 60% at 50% 45%, black, transparent 75%);
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 3;
  text-align: left;
  max-width: min(440px, 38vw);
  padding: 0 1.35rem;
  margin-right: auto;
  margin-left: max(1.35rem, calc((100% - var(--max)) / 2 + 1.35rem));
  text-shadow: 0 2px 24px rgba(6, 20, 40, 0.85), 0 0 40px rgba(6, 20, 40, 0.55);
}
.hero-content .tagline {
  max-width: 20rem;
  position: relative;
}
/* Soft vignette behind copy so the 3D ring never fights text */
.hero-content::before {
  content: "";
  position: absolute;
  inset: -1.75rem -1.25rem -1.75rem -2.25rem;
  background: linear-gradient(145deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02));
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 28px;
  backdrop-filter: blur(16px) saturate(130%);
  -webkit-backdrop-filter: blur(16px) saturate(130%);
  box-shadow: 0 1px 0 rgba(255,255,255,0.08) inset, 0 24px 60px rgba(0,0,0,0.25);
  z-index: -1;
  pointer-events: none;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--orange);
  background: rgba(255,107,0,0.1);
  border: 1px solid rgba(255, 107, 0, 0.32);
  padding: 0.42rem 0.85rem;
  border-radius: 999px;
  margin-bottom: 1.25rem;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}
.hero-badge::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 10px var(--orange-glow);
}

.hero h1 .accent {
  color: var(--orange);
  text-shadow: 0 0 40px rgba(255,107,0,0.35), 0 8px 40px rgba(0,0,0,0.4);
}
.hero h1 {
  margin: 0 0 0.85rem;
  font-size: clamp(2.55rem, 6.2vw, 4.05rem);
  letter-spacing: -0.048em;
  line-height: 0.98;
  font-weight: 850;
  color: var(--white);
  text-shadow: 0 10px 48px rgba(0, 0, 0, 0.5);
}

.tagline {
  margin: 0 0 1.6rem;
  font-size: clamp(1.02rem, 2.2vw, 1.2rem);
  color: rgba(214, 224, 236, 0.9);
  max-width: 28rem;
}

.hero-cta {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.78rem 1.4rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1.5px solid transparent;
  text-decoration: none;
  transition: transform 0.2s var(--ease), background 0.2s, border-color 0.2s, box-shadow 0.2s;
}
.btn:hover { text-decoration: none; transform: translateY(-2px); }

.btn-primary {
  background: linear-gradient(180deg, #ff7a1a 0%, var(--orange) 100%);
  color: var(--white);
  border-color: transparent;
  box-shadow: 0 8px 28px rgba(255, 107, 0, 0.35);
}
.btn-primary:hover {
  background: linear-gradient(180deg, #ff8a33 0%, #e05f00 100%);
  color: var(--white);
  box-shadow: 0 12px 32px rgba(255, 107, 0, 0.45);
}

.btn-ghost {
  background: var(--glass);
  color: var(--white);
  border-color: var(--glass-border);
  backdrop-filter: blur(8px);
}
.btn-ghost:hover {
  border-color: rgba(255, 107, 0, 0.55);
  color: var(--orange);
}

.scroll-hint {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  font-family: ui-monospace, Menlo, Consolas, monospace;
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(255,255,255,0.42);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
}
.scroll-hint span {
  width: 1px;
  height: 28px;
  background: linear-gradient(to bottom, var(--orange), transparent);
  animation: pulse-line 1.8s ease-in-out infinite;
}
@keyframes pulse-line {
  0%, 100% { opacity: 0.3; transform: scaleY(0.7); }
  50% { opacity: 1; transform: scaleY(1); }
}

/* Sections */
.section {
  padding: 4.5rem 0;
  position: relative;
}
.section-alt {
  background: linear-gradient(180deg, rgba(11,30,58,0.5) 0%, rgba(6,20,40,0.95) 100%);
}

.section h2 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.45rem, 3vw, 1.85rem);
  color: var(--white);
  letter-spacing: -0.02em;
}
.section > .container > p,
.section .lead {
  margin: 0 0 1.5rem;
  color: var(--muted);
  max-width: 40rem;
}

.accent-bar {
  width: 44px;
  height: 4px;
  background: linear-gradient(90deg, var(--orange), transparent);
  border-radius: 2px;
  margin-bottom: 1rem;
}

.about-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: 1fr;
}
@media (min-width: 700px) {
  .about-grid { grid-template-columns: 1fr 1fr; }
}

.card {
  background: linear-gradient(160deg, rgba(255,255,255,0.09), rgba(255,255,255,0.03));
  border: 1px solid rgba(255,255,255,0.14);
  border-radius: 22px;
  padding: 1.55rem 1.55rem;
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.1) inset,
    0 24px 56px rgba(0, 0, 0, 0.28);
  transform: translateZ(0);
  transition: transform 0.45s var(--ease), border-color 0.3s, box-shadow 0.45s;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(255, 107, 0, 0.4);
  box-shadow:
    0 1px 0 rgba(255,255,255,0.12) inset,
    0 28px 64px rgba(0, 0, 0, 0.4),
    0 0 48px rgba(255, 107, 0, 0.12);
}
.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.12rem;
  color: var(--white);
}
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.card-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: var(--orange-soft);
  color: var(--orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  margin-bottom: 0.9rem;
  border: 1px solid rgba(255, 107, 0, 0.22);
}

/* Reveal on scroll */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
}
.reveal.is-in {
  opacity: 1;
  transform: translateY(0);
}
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }

/* Page hero (inner pages) */
.page-hero {
  position: relative;
  padding: 3rem 0 2.25rem;
  overflow: hidden;
  background: linear-gradient(135deg, #0B1E3A 0%, #061428 100%);
  border-bottom: 1px solid var(--glass-border);
}
.page-hero::before {
  content: "";
  position: absolute;
  width: 320px; height: 320px;
  border-radius: 50%;
  background: rgba(255, 107, 0, 0.12);
  filter: blur(60px);
  top: -80px; right: 5%;
  pointer-events: none;
}
.page-hero h1 {
  margin: 0 0 0.45rem;
  font-size: clamp(1.65rem, 4vw, 2.25rem);
  letter-spacing: -0.025em;
  color: var(--white);
}
.page-hero p {
  margin: 0;
  color: rgba(214, 224, 236, 0.8);
  font-size: 0.98rem;
}

/* Apps */
.app-list {
  display: grid;
  gap: 1.35rem;
}

.app-card {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: 1.25rem;
  align-items: start;
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 20px;
  padding: 1.5rem;
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 50px rgba(0,0,0,0.22);
  transition: transform 0.35s var(--ease), border-color 0.25s;
}
.app-card:hover {
  transform: translateY(-3px);
  border-color: rgba(255, 107, 0, 0.4);
}

.app-icon { overflow: hidden;
  flex-shrink: 0;
  width: 72px;
  height: 72px;
  border-radius: 18px;
  background: linear-gradient(145deg, #123056, var(--navy));
  color: var(--orange);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.85rem;
  font-weight: 700;
  border: 1px solid var(--glass-border);
  box-shadow: 0 10px 28px rgba(0,0,0,0.3), inset 0 1px 0 rgba(255,255,255,0.08);
}

.badge {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: var(--orange-soft);
  color: var(--orange);
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  margin-bottom: 0.45rem;
  border: 1px solid rgba(255, 107, 0, 0.22);
}
.badge-muted {
  background: rgba(255,255,255,0.06);
  color: var(--muted);
  border-color: var(--glass-border);
}

.app-card h3 { margin: 0 0 0.4rem; font-size: 1.25rem; color: var(--white); }
.app-card p { margin: 0; color: var(--muted); }
.app-card .app-meta { margin-top: 0.85rem; font-size: 0.9rem; }

.placeholder-card {
  border-style: dashed;
  background: rgba(255,255,255,0.03);
  color: var(--muted);
  text-align: center;
  padding: 2rem 1.4rem;
  border-radius: 18px;
  border: 1px dashed var(--glass-border);
}

/* Privacy prose */
.prose {
  padding: 2.25rem 0 3.5rem;
  max-width: 760px;
}
.prose h2 {
  color: var(--white);
  font-size: 1.12rem;
  margin: 1.75rem 0 0.5rem;
  padding-top: 0.85rem;
  border-top: 1px solid var(--border);
}
.prose h2:first-of-type { border-top: none; margin-top: 0; padding-top: 0; }
.prose p { margin: 0 0 0.85rem; color: var(--text); }
.prose .meta {
  color: var(--muted);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}
.notice {
  background: var(--orange-soft);
  border-left: 4px solid var(--orange);
  padding: 0.9rem 1.05rem;
  border-radius: 0 12px 12px 0;
  margin-bottom: 1.5rem;
  font-size: 0.92rem;
  color: var(--text);
}

/* Contact */
.contact-box {
  background: var(--glass);
  border: 1px solid var(--glass-border);
  border-radius: 18px;
  padding: 1.75rem;
  max-width: 480px;
  backdrop-filter: blur(12px);
}
.contact-box dt {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
  margin-top: 1.1rem;
}
.contact-box dt:first-child { margin-top: 0; }
.contact-box dd {
  margin: 0.3rem 0 0;
  font-size: 1.08rem;
  font-weight: 650;
  color: var(--white);
}
.contact-box a { color: var(--orange); }

/* Footer */
.site-footer {
  background: #040e1c;
  color: rgba(255, 255, 255, 0.6);
  padding: 1.75rem 0;
  font-size: 0.9rem;
  margin-top: auto;
  border-top: 1px solid var(--glass-border);
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  align-items: center;
}
.site-footer a { color: var(--orange); }
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.1rem;
}

/* No-WebGL / reduced motion */
.no-webgl .hero-canvas { display: none !important; }
.no-webgl .hero-fallback { display: block; }
.has-webgl .hero-fallback { display: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hero-fallback .orb,
  .scroll-hint span,
  .btn { animation: none !important; transition: none !important; }
  .card:hover, .app-card:hover, .btn:hover { transform: none; }
}

@media (max-width: 720px) {
  .hero-content {
    margin-left: auto;
    margin-right: auto;
    text-align: center;
    max-width: 100%;
    text-shadow: none;
  }
  .hero-content::before { display: none; }
  .hero-content .tagline { max-width: 28rem; margin-left: auto; margin-right: auto; }
  .hero-cta { justify-content: center; }
  .hero { min-height: 560px; padding-top: 2.5rem; }
  .app-card { grid-template-columns: 1fr; justify-items: center; text-align: center; }
}

@media (max-width: 480px) {
  .nav a { padding: 0.35rem 0.5rem; font-size: 0.85rem; }
}


/* premium-mobile */
@media (max-width: 720px) {
  .hero { min-height: 760px; padding-bottom: 14rem; align-items: flex-start; padding-top: 1.25rem; }
  .hero-content { max-width: 100%; margin: 0.5rem auto 0; text-align: center; }
  .hero-content::before { inset: -1.1rem -0.6rem -1.1rem -0.6rem; border-radius: 22px; }
  .hero-content .tagline, .tagline { margin-left: auto; margin-right: auto; max-width: 22rem; }
  .hero-cta { justify-content: center; }
  .hero-content::before { inset: -1rem -0.5rem -1rem -0.5rem; }
  .nav { max-width: calc(100vw - 7rem); overflow-x: auto; flex-wrap: nowrap; }
  .nav a { white-space: nowrap; font-size: 0.82rem; padding: 0.35rem 0.6rem; }
}
