/* ============================================================
   linuxdo homepage — dark universe / liquid payment pulse
   ============================================================ */

:root {
  --bg: #070708;
  --bg-2: #0c0c0e;
  --ink: #f4f0e9;
  --ink-2: #a7a29a;
  --ink-3: #6f6a63;
  --brand: #e95420;
  --brand-2: #ff7a45;
  --line: rgba(244, 240, 233, 0.08);
  --radius: 14px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --nav-h: 68px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "PingFang SC", "Microsoft YaHei", sans-serif;
  line-height: 1.6;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--brand);
  color: #fff;
}

a {
  color: inherit;
  text-decoration: none;
}
i[data-lucide] {
  display: inline-flex;
  flex: none;
}

/* ---------- Preloader ---------- */
.loader {
  position: fixed;
  inset: 0;
  z-index: 999;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 0.6s var(--ease), visibility 0.6s;
  /* 防御:即使 JS 全部失效,4.5 秒后也自动淡出,避免永久卡在加载页 */
  animation: loader-auto-hide 0.6s ease 4.5s forwards;
}
@keyframes loader-auto-hide {
  to { opacity: 0; visibility: hidden; }
}
.loader.done {
  opacity: 0;
  visibility: hidden;
  animation: none;
}
.loader-inner {
  text-align: center;
}
.loader-mark {
  width: 44px;
  height: 44px;
  margin: 0 auto 18px;
  border-radius: 50%;
  background:
    radial-gradient(circle at 30% 30%, #ff9d6b, var(--brand) 60%, #b53a12);
  box-shadow: 0 0 60px rgba(233, 84, 32, 0.45);
  animation: pulse 1.4s ease-in-out infinite;
}
.loader-name {
  font-size: 14px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--ink-2);
  margin-bottom: 20px;
}
.loader-line {
  width: 180px;
  height: 1px;
  background: var(--line);
  overflow: hidden;
  margin: 0 auto;
}
.loader-line i {
  display: block;
  height: 100%;
  width: 40%;
  background: var(--brand);
  animation: loadslide 1.2s var(--ease) infinite;
}
@keyframes pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.08); opacity: 0.85; }
}
@keyframes loadslide {
  0% { transform: translateX(-120%); }
  100% { transform: translateX(320%); }
}

/* ---------- Scroll progress ---------- */
.progress {
  position: fixed;
  top: 0;
  left: 0;
  height: 2px;
  width: 100%;
  transform-origin: left;
  transform: scaleX(0);
  background: linear-gradient(90deg, var(--brand), var(--brand-2));
  z-index: 200;
}

/* ---------- Custom cursor ---------- */
.cursor {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 300;
  pointer-events: none;
  mix-blend-mode: difference;
  opacity: 0;
  transition: opacity 0.3s;
}
.cursor span {
  position: absolute;
  top: 0;
  left: 0;
  width: 8px;
  height: 8px;
  margin: -4px 0 0 -4px;
  border-radius: 50%;
  background: #fff;
}
.cursor.grow span {
  width: 44px;
  height: 44px;
  margin: -22px 0 0 -22px;
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.35);
  transition: width 0.25s var(--ease), height 0.25s var(--ease), margin 0.25s var(--ease);
}
@media (pointer: coarse) {
  .cursor { display: none; }
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  border-bottom: 1px solid transparent;
  transition: background 0.4s var(--ease), border-color 0.4s, backdrop-filter 0.4s;
}
.nav.scrolled {
  background: rgba(7, 7, 8, 0.72);
  backdrop-filter: blur(16px);
  border-color: var(--line);
}
.nav-inner {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 40px;
}
.nav-brand {
  font-size: 17px;
  font-weight: 800;
  letter-spacing: 0.06em;
  color: var(--ink);
}
.nav-brand::first-letter {
  color: var(--brand);
}
.nav-links {
  display: flex;
  gap: 30px;
  font-size: 14px;
  color: var(--ink-2);
}
.nav-links a {
  position: relative;
  padding: 6px 0;
  transition: color 0.2s;
}
.nav-links a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  width: 100%;
  height: 1px;
  background: var(--brand);
  transform: scaleX(0);
  transform-origin: right;
  transition: transform 0.3s var(--ease);
}
.nav-links a:hover {
  color: var(--ink);
}
.nav-links a:hover::after {
  transform: scaleX(1);
  transform-origin: left;
}
.nav-login {
  margin-left: auto;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 600;
  color: #fff;
  background: var(--brand);
  padding: 10px 20px;
  border-radius: 999px;
  transition: background 0.2s, transform 0.2s var(--ease), box-shadow 0.2s;
}
.nav-login:hover {
  background: var(--brand-2);
  box-shadow: 0 8px 30px rgba(233, 84, 32, 0.35);
  transform: translateY(-1px);
}
.nav-login svg {
  width: 15px;
  height: 15px;
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  padding: calc(var(--nav-h) + 60px) 24px 140px;
}
.hero-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-orb {
  position: absolute;
  width: 640px;
  height: 640px;
  border-radius: 50%;
  right: -160px;
  top: -160px;
  background: radial-gradient(circle at 35% 35%, rgba(233, 84, 32, 0.22), transparent 65%);
  filter: blur(30px);
  animation: drift 14s ease-in-out infinite;
  pointer-events: none;
}
@keyframes drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(-40px, 40px) scale(1.06); }
}
.hero-inner {
  position: relative;
  z-index: 2;
  text-align: center;
  width: min(960px, 100%);
}
.hero-eyebrow {
  font-size: 12px;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--brand-2);
  margin-bottom: 34px;
}
.hero-title {
  font-size: clamp(44px, 9vw, 118px);
  font-weight: 900;
  line-height: 0.98;
  letter-spacing: -0.03em;
  margin-bottom: 36px;
}
.hero-title .t-outline {
  display: block;
  color: transparent;
  -webkit-text-stroke: 1.5px rgba(244, 240, 233, 0.55);
}
.hero-title .t-solid {
  display: block;
  color: var(--ink);
}
.hero-title .t-solid em {
  font-style: normal;
  background: linear-gradient(100deg, var(--brand), var(--brand-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.hero-sub {
  max-width: 560px;
  margin: 0 auto 44px;
  font-size: 16px;
  color: var(--ink-2);
}
.hero-actions {
  display: flex;
  gap: 18px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: 46px;
}
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 600;
  padding: 15px 32px;
  border-radius: 999px;
  transition: all 0.25s var(--ease);
  will-change: transform;
}
.btn svg {
  width: 17px;
  height: 17px;
}
.btn-primary {
  background: var(--brand);
  color: #fff;
}
.btn-primary:hover {
  background: var(--brand-2);
  box-shadow: 0 14px 44px rgba(233, 84, 32, 0.4);
}
.btn-ghost {
  border: 1px solid var(--line);
  color: var(--ink-2);
}
.btn-ghost:hover {
  border-color: var(--ink-3);
  color: var(--ink);
}
.btn-xl {
  padding: 20px 46px;
  font-size: 17px;
}
.hero-tags {
  display: flex;
  gap: 26px;
  justify-content: center;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-2);
}
.hero-tags span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.hero-tags svg {
  width: 15px;
  height: 15px;
  color: var(--brand-2);
}

/* ---------- Ticker ---------- */
.ticker {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  border-top: 1px solid var(--line);
  overflow: hidden;
  padding: 18px 0;
  background: rgba(7, 7, 8, 0.6);
  backdrop-filter: blur(8px);
  text-align: center;
}
.ticker-track {
  display: inline-flex;
  gap: 48px;
  white-space: nowrap;
  padding-left: 100%; /* 起点在视口右缘之外,从右侧滚入 */
  animation: marquee 26s linear infinite;
  font-size: 13px;
  letter-spacing: 0.12em;
  color: var(--ink-2);
}
.ticker-track span {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}
.ticker-track i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brand);
  box-shadow: 0 0 12px rgba(233, 84, 32, 0.8);
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Reveal ---------- */
[data-reveal] {
  opacity: 0;
  transform: translateY(40px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}
[data-reveal].in {
  opacity: 1;
  transform: none;
}

/* ---------- Sections ---------- */
.section {
  padding: clamp(90px, 12vw, 150px) 24px;
}
.section-eyebrow {
  font-size: 12px;
  letter-spacing: 0.5em;
  text-transform: uppercase;
  color: var(--brand-2);
  margin-bottom: 20px;
}
.section-title {
  font-size: clamp(34px, 6vw, 72px);
  font-weight: 900;
  line-height: 1.02;
  letter-spacing: -0.02em;
}
.section-title em {
  font-style: normal;
  color: transparent;
  -webkit-text-stroke: 1.2px rgba(244, 240, 233, 0.5);
}
.section-head {
  width: min(1200px, 92vw);
  margin: 0 auto 70px;
}

/* ---------- Metrics ---------- */
.metrics {
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  background: var(--bg-2);
}
.metrics-inner {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
}
.metric {
  padding: 56px 24px;
  text-align: center;
  border-right: 1px solid var(--line);
}
.metric:last-child {
  border-right: none;
}
.metric-num {
  font-size: clamp(34px, 4.5vw, 58px);
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.metric-num .num {
  background: linear-gradient(180deg, var(--ink), var(--ink-3));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.metric-label {
  margin-top: 10px;
  font-size: 13px;
  letter-spacing: 0.14em;
  color: var(--ink-3);
}

/* ---------- Features ---------- */
.feat-grid {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}
.feat {
  position: relative;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 38px 30px;
  background: linear-gradient(160deg, rgba(255, 255, 255, 0.03), transparent 60%);
  transition: border-color 0.3s, background 0.3s;
  transform-style: preserve-3d;
}
.feat::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: var(--radius);
  background: radial-gradient(400px circle at var(--mx, 50%) var(--my, 50%), rgba(233, 84, 32, 0.12), transparent 60%);
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}
.feat:hover {
  border-color: rgba(233, 84, 32, 0.4);
}
.feat:hover::before {
  opacity: 1;
}
.feat-icon {
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(233, 84, 32, 0.12);
  color: var(--brand-2);
  margin-bottom: 24px;
  transform: translateZ(30px);
}
.feat-icon svg {
  width: 22px;
  height: 22px;
}
.feat h3 {
  font-size: 19px;
  font-weight: 700;
  margin-bottom: 10px;
  transform: translateZ(20px);
}
.feat p {
  font-size: 14px;
  color: var(--ink-2);
  transform: translateZ(10px);
}

/* ---------- Advantage ---------- */
.advantage {
  background: var(--bg-2);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.advantage-inner {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 80px;
  align-items: start;
}
.advantage-left .btn {
  margin-top: 44px;
}
.adv-row {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 22px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}
.adv-row:first-child {
  border-top: 1px solid var(--line);
}
.adv-num {
  font-size: 15px;
  font-weight: 800;
  color: var(--brand);
  letter-spacing: 0.1em;
}
.adv-row h3 {
  font-size: 18px;
  margin-bottom: 6px;
}
.adv-row p {
  font-size: 14px;
  color: var(--ink-2);
}

/* ---------- FAQ ---------- */
.faq-list {
  width: min(800px, 92vw);
  margin: 0 auto;
}
.faq-item {
  border-bottom: 1px solid var(--line);
}
.faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  background: none;
  border: none;
  color: var(--ink);
  font-size: 17px;
  font-weight: 600;
  padding: 26px 4px;
  cursor: pointer;
  text-align: left;
  font-family: inherit;
}
.faq-q svg {
  width: 20px;
  height: 20px;
  color: var(--brand-2);
  flex: none;
  transition: transform 0.35s var(--ease);
}
.faq-item.open .faq-q svg {
  transform: rotate(45deg);
}
.faq-a {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows 0.45s var(--ease);
}
.faq-item.open .faq-a {
  grid-template-rows: 1fr;
}
.faq-a > div {
  overflow: hidden;
}
.faq-a p {
  padding: 0 4px 26px;
  font-size: 14px;
  color: var(--ink-2);
}

/* ---------- CTA ---------- */
.cta {
  position: relative;
  overflow: hidden;
  padding: clamp(110px, 16vw, 190px) 24px;
  text-align: center;
  background:
    radial-gradient(ellipse at 50% 120%, rgba(233, 84, 32, 0.25), transparent 60%),
    var(--bg);
}
.cta-title {
  font-size: clamp(40px, 8vw, 100px);
  font-weight: 900;
  line-height: 1;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}
.cta p {
  font-size: 16px;
  color: var(--ink-2);
  margin-bottom: 46px;
}

/* ---------- Footer ---------- */
.footer {
  border-top: 1px solid var(--line);
  padding: 40px 24px;
}
.footer-inner {
  width: min(1200px, 92vw);
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 13px;
  color: var(--ink-3);
}
.footer-brand {
  font-size: 15px;
  font-weight: 800;
  color: var(--ink-2);
  letter-spacing: 0.08em;
}
.footer-legal {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
}
.footer-legal a {
  transition: color 0.2s;
}
.footer-legal a:hover {
  color: var(--ink);
}
.dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--ink-3);
}

/* ---------- Modals ---------- */
.modal {
  position: fixed;
  inset: 0;
  z-index: 150;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal.open {
  display: flex;
}
.modal-mask {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 6, 0.72);
  backdrop-filter: blur(10px);
  animation: fadein 0.3s;
}
@keyframes fadein {
  from { opacity: 0; }
}
.modal-box {
  position: relative;
  width: 400px;
  max-width: 100%;
  max-height: calc(100vh - 40px);
  background: var(--bg-2);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 40px 34px 32px;
  text-align: center;
  overflow-y: auto;
  animation: pop 0.4s var(--ease);
  box-shadow: 0 40px 120px rgba(0, 0, 0, 0.6);
}
@keyframes pop {
  from { opacity: 0; transform: translateY(24px) scale(0.97); }
}
.modal-box-wide {
  width: 720px;
  text-align: left;
}
.modal-x {
  position: absolute;
  top: 18px;
  right: 18px;
  width: 36px;
  height: 36px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.06);
  color: var(--ink-2);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, transform 0.2s;
}
.modal-x:hover {
  background: rgba(233, 84, 32, 0.2);
  color: var(--brand-2);
  transform: rotate(90deg);
}
.modal-x svg {
  width: 16px;
  height: 16px;
}
.modal-eyebrow {
  font-size: 11px;
  letter-spacing: 0.4em;
  text-transform: uppercase;
  color: var(--brand-2);
  margin-bottom: 12px;
}
.modal-title {
  font-size: 26px;
  font-weight: 800;
  margin-bottom: 6px;
}
.modal-sub {
  font-size: 13px;
  color: var(--ink-2);
  margin-bottom: 28px;
}
.modal-error {
  font-size: 12px;
  color: #ff8a75;
  background: rgba(233, 84, 32, 0.12);
  border: 1px solid rgba(233, 84, 32, 0.3);
  border-radius: 10px;
  padding: 10px 14px;
  margin-bottom: 16px;
}
.btn-login {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 14px 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.04);
  color: var(--ink);
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  transition: border-color 0.2s, background 0.2s;
}
.btn-login:hover:not(:disabled) {
  border-color: rgba(233, 84, 32, 0.5);
  background: rgba(233, 84, 32, 0.1);
}
.btn-login:disabled {
  cursor: not-allowed;
  opacity: 0.45;
}
.btn-login svg {
  width: 18px;
  height: 18px;
  color: var(--brand-2);
}
.agree {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 8px;
  margin-top: 18px;
  font-size: 12px;
  color: var(--ink-3);
  text-align: left;
  line-height: 1.5;
}
.agree input {
  width: 15px;
  height: 15px;
  margin-top: 2px;
  accent-color: var(--brand);
  cursor: pointer;
  flex: none;
}
.agree a {
  color: var(--brand-2);
}
.agree a:hover {
  text-decoration: underline;
}
.modal-body {
  font-size: 13px;
  line-height: 1.85;
  color: var(--ink-2);
  padding-top: 8px;
}
.modal-body h2 {
  font-size: 15px;
  color: var(--ink);
  margin: 22px 0 8px;
}
.modal-body h2:first-child {
  margin-top: 0;
}
.modal-body p {
  margin-bottom: 8px;
}

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .feat-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .metrics-inner {
    grid-template-columns: repeat(2, 1fr);
  }
  .metric:nth-child(2) {
    border-right: none;
  }
  .metric:nth-child(-n + 2) {
    border-bottom: 1px solid var(--line);
  }
  .advantage-inner {
    grid-template-columns: 1fr;
    gap: 50px;
  }
}
@media (max-width: 600px) {
  .nav-links {
    display: none;
  }
  .feat-grid {
    grid-template-columns: 1fr;
  }
  .hero-actions {
    flex-direction: column;
  }
  .btn {
    width: 100%;
    justify-content: center;
  }
  .hero-tags {
    flex-direction: column;
    gap: 12px;
  }
}
