/* ============================================================
   Web3e — modern design system
   AI + Blockchain + Crypto. Light, fast, mobile-first.
   ============================================================ */

:root {
  --bg: #ffffff;
  --bg-soft: #f5f7fb;
  --bg-tint: #eef1ff;
  --ink: #0b1020;
  --ink-2: #1b2337;
  --muted: #5c6675;
  --line: #e6eaf2;
  --brand: #5b3df5;
  --brand-2: #00b8ff;
  --brand-deep: #4526d8;
  --grad: linear-gradient(135deg, #5b3df5 0%, #7a2ff0 45%, #00b8ff 100%);
  --grad-btn: linear-gradient(135deg, #5b3df5 0%, #7a2ff0 100%);
  --grad-soft: linear-gradient(135deg, rgba(91,61,245,.08), rgba(0,184,255,.08));
  --shadow-sm: 0 2px 8px rgba(16,24,64,.06);
  --shadow: 0 12px 34px rgba(16,24,64,.10);
  --radius: 16px;
  --radius-sm: 10px;
  --maxw: 1140px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Inter, Helvetica, Arial, sans-serif;
}

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

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

body {
  margin: 0;
  font-family: var(--font);
  color: var(--ink);
  background: var(--bg);
  line-height: 1.65;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }
a { color: var(--brand); text-decoration: none; }
a:hover { color: var(--brand-deep); }

h1, h2, h3, h4 {
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--ink);
  margin: 0 0 .5em;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.4rem); }
h3 { font-size: 1.25rem; }

p { margin: 0 0 1em; }

.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 22px; }
.section { padding: 76px 0; }
.section-soft { background: var(--bg-soft); }
.section-head { max-width: 680px; margin: 0 auto 48px; }
.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--brand);
  margin-bottom: 12px;
}
.lead { font-size: 1.12rem; color: var(--muted); }
.center { text-align: center; }
.muted { color: var(--muted); }

/* Animated gradient text */
.grad-text {
  background: linear-gradient(90deg, #7c5cff, #38bdf8, #22d3ee, #7c5cff);
  background-size: 300% 100%;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  animation: gradMove 9s linear infinite;
}
@keyframes gradMove { to { background-position: 300% 0; } }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: .96rem;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .18s ease, box-shadow .18s ease, background .18s ease, color .18s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--grad-btn); color: #fff; box-shadow: 0 10px 26px rgba(91,61,245,.32); }
.btn-primary:hover { transform: translateY(-2px); box-shadow: 0 14px 34px rgba(91,61,245,.42); color: #fff; }
.btn-ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn-ghost:hover { background: var(--ink); color: #fff; }
.btn-ghost-light { border-color: rgba(255,255,255,.35); color: #fff; background: transparent; }
.btn-ghost-light:hover { background: #fff; color: var(--ink); }
.btn-white { background: #fff; color: var(--ink); }
.btn-white:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-sm { padding: 9px 16px; font-size: .88rem; }
.btn-lg { padding: 15px 30px; font-size: 1.04rem; }

/* Header / Nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.nav-wrap { display: flex; align-items: center; gap: 22px; height: 68px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--ink); font-weight: 800; font-size: 1.35rem; letter-spacing: -0.03em; }
.brand .accent {
  background: var(--grad);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}
.site-nav { display: flex; align-items: center; gap: 4px; margin-left: auto; }
.site-nav a {
  color: var(--muted);
  font-weight: 600;
  font-size: .92rem;
  padding: 8px 12px;
  border-radius: 9px;
}
.site-nav a:hover { color: var(--ink); background: var(--bg-soft); }
.site-nav a.active { color: var(--brand); }
.nav-cta { margin-left: 6px; background: #fff; color: var(--brand); border-color: var(--line); box-shadow: none; }
.nav-cta:hover { background: var(--bg-soft); color: var(--brand-deep); border-color: var(--brand); box-shadow: none; transform: none; }
.nav-toggle {
  display: none;
  margin-left: auto;
  background: none;
  border: 0;
  width: 44px;
  height: 44px;
  cursor: pointer;
}
.nav-toggle span { display: block; width: 24px; height: 2px; background: var(--ink); margin: 5px auto; border-radius: 2px; transition: .25s; }
.nav-toggle.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { opacity: 0; }
.nav-toggle.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Hero (dark) */
.hero {
  position: relative;
  overflow: hidden;
  background: #060913;
  color: #fff;
  padding: 96px 0 92px;
}
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.hero-bg::before {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255,255,255,.05) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255,255,255,.05) 1px, transparent 1px);
  background-size: 54px 54px;
  -webkit-mask-image: radial-gradient(circle at 50% 0%, #000 25%, transparent 72%);
  mask-image: radial-gradient(circle at 50% 0%, #000 25%, transparent 72%);
}
.orb { position: absolute; border-radius: 50%; filter: blur(90px); opacity: .6; }
.orb-a { width: 500px; height: 500px; background: radial-gradient(circle, rgba(91,61,245,.8), transparent 65%); top: -180px; left: -90px; }
.orb-b { width: 440px; height: 440px; background: radial-gradient(circle, rgba(0,184,255,.6), transparent 65%); top: -140px; right: -70px; }
.orb-c { width: 400px; height: 400px; background: radial-gradient(circle, rgba(124,45,255,.55), transparent 65%); bottom: -200px; left: 38%; }
.hero-inner { position: relative; z-index: 2; max-width: 900px; margin: 0 auto; text-align: center; }
.hero-badge {
  display: inline-flex; align-items: center; gap: 9px;
  border: 1px solid rgba(255,255,255,.16); background: rgba(255,255,255,.06);
  padding: 8px 16px; border-radius: 999px; font-size: .82rem; font-weight: 700;
  color: #dbe1f0; letter-spacing: .06em; text-transform: uppercase;
}
.hero-badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--grad); box-shadow: 0 0 12px rgba(0,184,255,.8); }
.hero h1 { color: #fff; font-size: clamp(2.5rem, 6vw, 4.1rem); margin: 20px 0 18px; letter-spacing: -0.03em; }
.hero-sub { color: #aeb7cc; font-size: 1.18rem; max-width: 660px; margin: 0 auto 32px; }
.hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.hero-chips { margin-top: 44px; display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; }
.hero-chip {
  border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.05);
  color: #cdd5e8; padding: 8px 16px; border-radius: 999px; font-size: .85rem; font-weight: 600;
}

/* Asset strip */
.asset-strip { padding: 26px 0; border-bottom: 1px solid var(--line); background: var(--bg); }
.asset-strip .container { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 26px; }
.asset-strip .label { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); font-weight: 700; }
.asset { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--ink-2); font-size: .95rem; }
.asset img { width: 26px; height: 26px; }

/* AI services */
.ai-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.ai-card {
  position: relative;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 26px;
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.ai-card::after {
  content: ""; position: absolute; top: -46px; right: -46px; width: 150px; height: 150px;
  background: radial-gradient(circle, rgba(91,61,245,.16), transparent 70%);
  border-radius: 50%; opacity: 0; transition: opacity .25s ease;
}
.ai-card:hover { transform: translateY(-6px); box-shadow: 0 26px 54px rgba(91,61,245,.18); border-color: transparent; }
.ai-card:hover::after { opacity: 1; }
.ai-icon {
  width: 56px; height: 56px; border-radius: 15px;
  background: var(--grad); color: #fff;
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  box-shadow: 0 10px 22px rgba(91,61,245,.35);
}
.ai-icon svg { width: 27px; height: 27px; }
.ai-card h3 { font-size: 1.12rem; margin-bottom: 8px; }
.ai-card p { color: var(--muted); font-size: .95rem; margin: 0; }

/* Cards grid */
.grid { display: grid; gap: 22px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }

.card {
  background: var(--bg);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.card .icon {
  width: 52px; height: 52px; border-radius: 13px;
  background: var(--grad-soft);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
}
.card .icon img { width: 34px; height: 34px; object-fit: contain; }
.card h3 { font-size: 1.08rem; margin-bottom: 8px; }
.card p { font-size: .95rem; color: var(--muted); margin: 0; }
.card a { display: inline-flex; align-items: center; gap: 6px; margin-top: 14px; font-weight: 700; font-size: .9rem; }
.card a .arr { transition: transform .18s; }
.card a:hover .arr { transform: translateX(3px); }

/* Feature two-column */
.feature { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: center; }
.feature.rev .feature-media { order: 2; }
.feature-media { border-radius: var(--radius); overflow: hidden; background: var(--bg-soft); box-shadow: var(--shadow-sm); }
.feature-media img { width: 100%; height: auto; display: block; }
.feature-body .check-list { list-style: none; padding: 0; margin: 20px 0 26px; display: grid; gap: 10px; }
.feature-body .check-list li { display: flex; gap: 10px; align-items: flex-start; color: var(--ink-2); }
.feature-body .check-list .tick { flex: 0 0 auto; width: 22px; height: 22px; border-radius: 50%; background: var(--grad); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-size: .8rem; font-weight: 800; margin-top: 2px; }

/* Page hero (subpages) */
.page-hero {
  background:
    radial-gradient(800px 400px at 90% -20%, rgba(0,184,255,.16), transparent 60%),
    radial-gradient(700px 400px at 0% 10%, rgba(91,61,245,.14), transparent 55%),
    var(--bg);
  padding: 72px 0 56px;
  border-bottom: 1px solid var(--line);
}
.page-hero h1 { max-width: 760px; }
.page-hero .lead { max-width: 680px; }
.breadcrumb { font-size: .85rem; color: var(--muted); margin-bottom: 14px; }
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--brand); }

/* Prose (content pages) */
.prose { max-width: 780px; }
.prose h2 { margin-top: 2.2em; }
.prose h3 { margin-top: 1.8em; }
.prose p { color: var(--ink-2); }
.prose ul { padding-left: 1.2em; color: var(--ink-2); }
.prose ul li { margin-bottom: .5em; }
.prose .lead { font-size: 1.18rem; }

/* Service rows (service.html) */
.service-row { display: grid; grid-template-columns: 1fr 1fr; gap: 44px; align-items: center; padding: 40px 0; border-bottom: 1px solid var(--line); }
.service-row:last-child { border-bottom: 0; }
.service-row.rev .service-media { order: 2; }
.service-media { border-radius: var(--radius); overflow: hidden; background: var(--bg-soft); box-shadow: var(--shadow-sm); }
.service-media img { width: 100%; height: auto; display: block; }
.service-body h2 { font-size: 1.7rem; }
.service-body p { color: var(--muted); }
.service-num { font-size: .8rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--brand); }

/* Contact */
.contact-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: 48px; align-items: start; }
.contact-card { background: var(--ink); color: #fff; border-radius: var(--radius); padding: 34px; }
.contact-card h2 { color: #fff; }
.contact-card .c-line { display: flex; align-items: center; gap: 12px; margin: 14px 0; color: #cfd4e4; }
.contact-card .c-line .ic { width: 40px; height: 40px; border-radius: 10px; background: rgba(255,255,255,.08); display: flex; align-items: center; justify-content: center; }
.contact-card a { color: #fff; }
.form { display: grid; gap: 16px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field label { display: block; font-size: .86rem; font-weight: 700; margin-bottom: 6px; }
.field input, .field textarea {
  width: 100%; padding: 13px 15px; font: inherit; color: var(--ink);
  border: 1px solid var(--line); border-radius: 11px; background: var(--bg);
  transition: border-color .15s, box-shadow .15s;
}
.field input:focus, .field textarea:focus { outline: none; border-color: var(--brand); box-shadow: 0 0 0 3px rgba(91,61,245,.12); }
.field textarea { resize: vertical; min-height: 130px; }

/* Email box */
.email-box {
  background: var(--grad-soft);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 30px;
  text-align: center;
}
.email-box .big { font-size: 1.4rem; font-weight: 800; background: var(--grad); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; color: transparent; word-break: break-all; }

/* Footer */
.site-footer { background: var(--ink); color: #b7bece; padding: 64px 0 0; }
.site-footer .foot-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1.3fr; gap: 34px; padding-bottom: 44px; }
.site-footer .foot-brand { color: #fff; font-weight: 800; font-size: 1.25rem; letter-spacing: -0.02em; }
.site-footer p { font-size: .92rem; margin-top: 14px; }
.site-footer h4 { color: #fff; font-size: .95rem; margin-bottom: 14px; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 9px; }
.site-footer ul a { color: #b7bece; font-size: .92rem; }
.site-footer ul a:hover { color: #fff; }
.foot-bottom { border-top: 1px solid rgba(255,255,255,.1); padding: 20px 0; text-align: center; font-size: .86rem; color: #8a92a6; }

/* Reveal animation */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }

/* Responsive */
@media (max-width: 980px) {
  .hero-grid, .feature, .contact-grid, .service-row { grid-template-columns: 1fr; gap: 32px; }
  .feature.rev .feature-media, .service-row.rev .service-media { order: 0; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3, .ai-grid { grid-template-columns: repeat(2, 1fr); }
  .site-footer .foot-grid { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .site-nav {
    position: absolute; top: 68px; left: 0; right: 0;
    flex-direction: column; align-items: stretch;
    background: #fff; border-bottom: 1px solid var(--line);
    padding: 12px 18px 18px; gap: 2px;
    display: none;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 12px; font-size: 1rem; border-radius: 10px; }
  .nav-cta { margin-left: 0; width: 100%; justify-content: center; }
}

@media (max-width: 560px) {
  .section { padding: 54px 0; }
  .hero { padding: 68px 0 64px; }
  .grid-2, .grid-3, .grid-4, .ai-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .site-footer .foot-grid { grid-template-columns: 1fr; }
  .btn-lg { padding: 14px 24px; }
}
