/* Tablingo Website — Modern Dark Theme */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --primary:     #7c6fff;
  --primary-d:   #6355e8;
  --primary-l:   #a89fff;
  --gradient:    linear-gradient(135deg, #6c63ff 0%, #a855f7 100%);
  --text:        #e2e2f0;
  --text-dim:    #9090b8;
  --muted:       #5e5e7a;
  --border:      rgba(255,255,255,0.07);
  --border-h:    rgba(255,255,255,0.13);
  --bg:          #06060f;
  --surface:     #0c0c1e;
  --surface-2:   #111128;
  --card-bg:     rgba(255,255,255,0.03);
  --card-hover:  rgba(255,255,255,0.06);
  --white:       #ffffff;
  --error:       #f87171;
  --error-bg:    rgba(248,113,113,0.1);
  --success:     #34d399;
  --success-bg:  rgba(52,211,153,0.1);
  --info-bg:     rgba(124,111,255,0.1);
  --radius:      12px;
  --radius-lg:   16px;
  --shadow:      0 8px 40px rgba(0,0,0,0.55);
  --glow-purple: 0 0 80px rgba(108,99,255,0.18);
}

html { scroll-behavior: smooth; }

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Inter, Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary-l); text-decoration: none; }
a:hover { color: var(--primary-l); text-decoration: underline; }

/* ── Nav ──────────────────────────────────────────────────────── */
nav {
  background: rgba(6, 6, 15, 0.82);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border-bottom: 1px solid var(--border);
  padding: 0 40px;
  height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: sticky;
  top: 0;
  z-index: 100;
}

.nav-brand {
  text-decoration: none;
}
.nav-brand:hover { text-decoration: none; }

.wordmark {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 3px;
  line-height: 1;
}
.wordmark-text {
  font-size: 26px;
  font-weight: 900;
  letter-spacing: -0.8px;
  line-height: 1;
}
.wordmark-sub {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-dim);
  line-height: 1;
}

.nav-links { display: flex; align-items: center; gap: 4px; }
.nav-links > a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dim);
  padding: 6px 14px;
  border-radius: 8px;
  transition: color 0.15s, background 0.15s;
}
.nav-links > a:hover {
  color: var(--text);
  background: rgba(255,255,255,0.06);
  text-decoration: none;
}

.btn-nav {
  background: var(--primary) !important;
  color: #fff !important;
  padding: 8px 18px !important;
  border-radius: 8px !important;
  font-weight: 600 !important;
  transition: all 0.15s !important;
  margin-left: 4px;
}
.btn-nav:hover {
  background: var(--primary-d) !important;
  text-decoration: none !important;
  box-shadow: 0 0 24px rgba(124,111,255,0.4) !important;
  color: #fff !important;
}

/* ── Buttons ──────────────────────────────────────────────────── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 24px;
  border-radius: var(--radius);
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: all 0.15s;
  text-decoration: none;
  font-family: inherit;
  line-height: 1;
}
.btn:disabled { opacity: 0.45; cursor: not-allowed; pointer-events: none; }

.btn-primary {
  background: var(--gradient);
  color: #fff;
  box-shadow: 0 4px 20px rgba(108,99,255,0.3);
}
.btn-primary:hover:not(:disabled) {
  transform: translateY(-1px);
  box-shadow: 0 8px 32px rgba(108,99,255,0.5);
  text-decoration: none;
  color: #fff;
}

.btn-secondary {
  background: rgba(255,255,255,0.07);
  color: var(--text);
  border: 1px solid var(--border-h);
}
.btn-secondary:hover:not(:disabled) {
  background: rgba(255,255,255,0.12);
  text-decoration: none;
  color: var(--text);
}

.btn-outline {
  background: transparent;
  color: var(--primary-l);
  border: 1.5px solid rgba(124,111,255,0.35);
}
.btn-outline:hover:not(:disabled) {
  background: rgba(124,111,255,0.1);
  border-color: rgba(124,111,255,0.6);
  text-decoration: none;
  color: var(--primary-l);
}

.btn-full { width: 100%; }
.btn-lg { padding: 14px 36px; font-size: 16px; }

/* ── Card ─────────────────────────────────────────────────────── */
.card {
  background: var(--surface-2);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-h);
  padding: 32px;
}

/* ── Form elements ────────────────────────────────────────────── */
.form-group { margin-bottom: 20px; }

.form-group label {
  display: block;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-dim);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.form-group input {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid var(--border-h);
  border-radius: 10px;
  font-size: 15px;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  background: rgba(255,255,255,0.04);
  color: var(--text);
  font-family: inherit;
}
.form-group input::placeholder { color: var(--muted); }
.form-group input:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(124,111,255,0.15);
}
.form-group input.error { border-color: var(--error); }

/* ── Alerts ───────────────────────────────────────────────────── */
.alert {
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 500;
  margin-bottom: 20px;
  line-height: 1.5;
}
.alert-error   { background: var(--error-bg);   color: var(--error);   border: 1px solid rgba(248,113,113,0.25); }
.alert-success { background: var(--success-bg); color: var(--success); border: 1px solid rgba(52,211,153,0.25); }
.alert-info    { background: var(--info-bg);    color: var(--primary-l); border: 1px solid rgba(124,111,255,0.25); }
.hidden { display: none !important; }

/* ── Badge ────────────────────────────────────────────────────── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-free { background: rgba(255,255,255,0.08); color: var(--text-dim); }
.badge-pro  { background: var(--gradient); color: #fff; }

/* ── Auth pages ───────────────────────────────────────────────── */
.auth-page {
  min-height: calc(100vh - 64px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 16px;
  background: radial-gradient(ellipse 80% 50% at 50% -10%, rgba(108,99,255,0.13), transparent);
}
.auth-box {
  width: 100%;
  max-width: 420px;
}
.auth-box h1 {
  font-size: 26px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 6px;
}
.auth-box .subtitle {
  color: var(--text-dim);
  font-size: 15px;
  margin-bottom: 28px;
}
.auth-footer {
  text-align: center;
  font-size: 14px;
  color: var(--text-dim);
  margin-top: 20px;
}
.auth-footer a { font-weight: 600; color: var(--primary-l); }

/* ── Hero ─────────────────────────────────────────────────────── */
.hero-wrap {
  position: relative;
  overflow: hidden;
}
.hero-wrap::before {
  content: '';
  position: absolute;
  width: 900px;
  height: 600px;
  background: radial-gradient(ellipse, rgba(108,99,255,0.13) 0%, transparent 65%);
  left: 50%;
  top: -100px;
  transform: translateX(-50%);
  pointer-events: none;
}

.hero {
  text-align: center;
  padding: 96px 24px 72px;
  max-width: 860px;
  margin: 0 auto;
  position: relative;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(108,99,255,0.1);
  border: 1px solid rgba(108,99,255,0.28);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  color: var(--primary-l);
  margin-bottom: 28px;
  letter-spacing: -0.1px;
}
.hero-badge-dot {
  width: 6px;
  height: 6px;
  background: var(--success);
  border-radius: 50%;
  flex-shrink: 0;
  animation: pulse-dot 2.2s ease infinite;
}
@keyframes pulse-dot {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.5; transform: scale(0.75); }
}

.hero h1 {
  font-size: clamp(38px, 5.5vw, 64px);
  font-weight: 900;
  line-height: 1.08;
  letter-spacing: -2px;
  margin-bottom: 22px;
  color: var(--text);
}
.gradient-text {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero > p {
  font-size: 18px;
  color: var(--text-dim);
  max-width: 520px;
  margin: 0 auto 40px;
  line-height: 1.7;
}
.hero-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 16px;
}
.hero-note {
  font-size: 13px;
  color: var(--muted);
  margin-top: 14px;
}

/* ── Browser Mockup ───────────────────────────────────────────── */
.mockup-section {
  max-width: 820px;
  margin: 0 auto;
  padding: 0 24px 80px;
  position: relative;
}
.mockup-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 70% 60% at 50% 100%, rgba(108,99,255,0.12), transparent);
  pointer-events: none;
}
.mockup-browser {
  background: var(--surface);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-h);
  box-shadow: var(--shadow), var(--glow-purple);
  overflow: hidden;
  position: relative;
}
.mockup-bar {
  background: var(--surface-2);
  padding: 12px 16px;
  display: flex;
  align-items: center;
  gap: 12px;
  border-bottom: 1px solid var(--border);
}
.mockup-dots { display: flex; gap: 6px; flex-shrink: 0; }
.mockup-dots span { width: 10px; height: 10px; border-radius: 50%; }
.mockup-dots span:nth-child(1) { background: #ff5f57; }
.mockup-dots span:nth-child(2) { background: #febc2e; }
.mockup-dots span:nth-child(3) { background: #28c840; }

.mockup-url {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 4px 14px;
  font-size: 12px;
  color: var(--muted);
  flex: 1;
  max-width: 340px;
  margin: 0 auto;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.mockup-content {
  position: relative;
  aspect-ratio: 16 / 8;
  background: linear-gradient(160deg, #0a0a1e 0%, #141438 40%, #0a0a1a 100%);
  display: flex;
  align-items: flex-end;
  overflow: hidden;
}
.mockup-video-bg {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 60% 40% at 30% 40%, rgba(80,60,160,0.25), transparent),
    radial-gradient(ellipse 40% 30% at 70% 60%, rgba(40,20,100,0.2), transparent);
}
.mockup-play {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.08);
  border: 1.5px solid rgba(255,255,255,0.15);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(6px);
}
.mockup-play::after {
  content: '';
  width: 0;
  height: 0;
  border-style: solid;
  border-width: 9px 0 9px 16px;
  border-color: transparent transparent transparent rgba(255,255,255,0.8);
  margin-left: 3px;
}

.mockup-subtitles {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 24px 28px 20px;
  background: linear-gradient(to top, rgba(0,0,0,0.88) 0%, rgba(0,0,0,0) 100%);
}
.sub-original {
  display: block;
  font-size: clamp(11px, 1.4vw, 13px);
  color: rgba(255,255,255,0.55);
  margin-bottom: 5px;
  font-weight: 400;
  letter-spacing: 0.1px;
}
.sub-translated {
  display: block;
  font-size: clamp(14px, 2.2vw, 20px);
  color: #fff;
  font-weight: 700;
  text-shadow: 0 2px 8px rgba(0,0,0,0.9);
  letter-spacing: -0.2px;
}
.sub-cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  background: var(--primary-l);
  margin-left: 3px;
  vertical-align: text-bottom;
  border-radius: 1px;
  animation: blink-cursor 1s step-end infinite;
}
@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.mockup-badge {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(124,111,255,0.15);
  border: 1px solid rgba(124,111,255,0.3);
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 11px;
  font-weight: 700;
  color: var(--primary-l);
  display: flex;
  align-items: center;
  gap: 5px;
  backdrop-filter: blur(8px);
}
.mockup-badge-dot {
  width: 5px;
  height: 5px;
  background: var(--success);
  border-radius: 50%;
  animation: pulse-dot 2.2s ease infinite;
}

/* ── Trust strip ──────────────────────────────────────────────── */
.trust-strip {
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}
.trust-item {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  padding: 0 12px;
}
.trust-item:not(:last-child) {
  border-right: 1px solid var(--border-h);
}
.trust-icon { font-size: 15px; }

/* ── Section common ───────────────────────────────────────────── */
.section-label {
  display: inline-block;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--primary);
  margin-bottom: 14px;
}
.section-title {
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 900;
  letter-spacing: -1px;
  line-height: 1.12;
  margin-bottom: 12px;
}
.section-sub {
  font-size: 17px;
  color: var(--text-dim);
  line-height: 1.7;
  max-width: 520px;
}

/* ── How it works ─────────────────────────────────────────────── */
.how-section {
  max-width: 920px;
  margin: 0 auto;
  padding: 80px 24px;
  text-align: center;
}
.how-section .section-sub { margin: 0 auto 60px; }

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
  position: relative;
}
.steps::before {
  content: '';
  position: absolute;
  top: 27px;
  left: calc(100% / 6);
  right: calc(100% / 6);
  height: 1px;
  background: linear-gradient(to right, transparent, var(--border-h) 20%, var(--border-h) 80%, transparent);
  pointer-events: none;
}

.step { padding: 0 24px; text-align: center; }
.step-num {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--gradient);
  color: #fff;
  font-size: 20px;
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  box-shadow: 0 6px 24px rgba(108,99,255,0.4);
  position: relative;
  z-index: 1;
}
.step h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.2px;
}
.step p {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.65;
}

/* ── Features grid ────────────────────────────────────────────── */
.features-section {
  padding: 0 24px 80px;
  text-align: center;
}
.features-section .section-sub { margin: 0 auto 48px; }

.features {
  max-width: 1000px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 14px;
}
.feature-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  text-align: left;
  transition: background 0.2s, border-color 0.2s, transform 0.2s;
}
.feature-card:hover {
  background: var(--card-hover);
  border-color: var(--border-h);
  transform: translateY(-2px);
}
.feature-icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: rgba(124,111,255,0.1);
  border: 1px solid rgba(124,111,255,0.18);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  margin-bottom: 18px;
}
.feature-card h3 {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.2px;
}
.feature-card p {
  font-size: 14px;
  color: var(--text-dim);
  line-height: 1.65;
}

/* ── CTA section ──────────────────────────────────────────────── */
.cta-section {
  padding: 0 24px 80px;
}
.cta-card {
  max-width: 740px;
  margin: 0 auto;
  background: linear-gradient(135deg,
    rgba(108,99,255,0.12) 0%,
    rgba(168,85,247,0.08) 100%);
  border: 1px solid rgba(124,111,255,0.28);
  border-radius: 24px;
  padding: 60px 48px;
  text-align: center;
  position: relative;
  overflow: hidden;
}
.cta-card::before {
  content: '';
  position: absolute;
  width: 500px;
  height: 500px;
  background: radial-gradient(ellipse, rgba(124,111,255,0.1), transparent 65%);
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  pointer-events: none;
}
.cta-card h2 {
  font-size: clamp(24px, 3.5vw, 36px);
  font-weight: 900;
  letter-spacing: -0.8px;
  margin-bottom: 12px;
  position: relative;
}
.cta-card p {
  font-size: 16px;
  color: var(--text-dim);
  margin-bottom: 36px;
  position: relative;
}
.cta-actions {
  display: flex;
  gap: 12px;
  justify-content: center;
  flex-wrap: wrap;
  position: relative;
}

/* ── Pricing ──────────────────────────────────────────────────── */
.pricing-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 80px 24px;
}
.pricing-page h1 {
  text-align: center;
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 900;
  letter-spacing: -1.2px;
  margin-bottom: 10px;
}
.pricing-page .lead {
  text-align: center;
  color: var(--text-dim);
  font-size: 18px;
  margin-bottom: 60px;
}
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  align-items: start;
}
.pricing-card {
  background: var(--surface-2);
  border: 1.5px solid var(--border-h);
  border-radius: 20px;
  padding: 36px;
}
.pricing-card.featured {
  background: linear-gradient(150deg,
    rgba(108,99,255,0.1) 0%,
    rgba(168,85,247,0.06) 100%);
  border-color: rgba(124,111,255,0.45);
  box-shadow: 0 0 60px rgba(108,99,255,0.12);
  position: relative;
}
.featured-badge {
  position: absolute;
  top: -13px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gradient);
  color: #fff;
  padding: 4px 18px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  white-space: nowrap;
}
.pricing-card .plan-name {
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-dim);
  margin-bottom: 18px;
}
.pricing-card.featured .plan-name { color: var(--primary-l); }
.pricing-card .price {
  font-size: 54px;
  font-weight: 900;
  line-height: 1;
  letter-spacing: -2.5px;
  margin-bottom: 4px;
}
.pricing-card.featured .price {
  background: var(--gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.pricing-card .price-period {
  font-size: 14px;
  color: var(--muted);
  margin-bottom: 30px;
}
.pricing-card ul { list-style: none; margin-bottom: 30px; }
.pricing-card ul li {
  font-size: 14px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
  display: flex;
  gap: 10px;
  align-items: flex-start;
  line-height: 1.5;
}
.pricing-card ul li:last-child { border-bottom: none; }
.pricing-card ul li .check { color: var(--success); font-weight: 700; flex-shrink: 0; margin-top: 1px; }
.pricing-card ul li .cross { color: var(--muted); flex-shrink: 0; margin-top: 1px; }

/* ── Dashboard ────────────────────────────────────────────────── */
.dashboard-page {
  max-width: 640px;
  margin: 56px auto;
  padding: 0 24px;
}
.dashboard-page h1 {
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.5px;
  margin-bottom: 32px;
}
.info-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 0;
  border-bottom: 1px solid var(--border);
  font-size: 15px;
  gap: 16px;
}
.info-row:last-child { border-bottom: none; }
.info-label {
  color: var(--text-dim);
  font-size: 13px;
  font-weight: 500;
  flex-shrink: 0;
}
.info-value { font-weight: 600; text-align: right; }
.dashboard-actions {
  margin-top: 24px;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ── Footer ───────────────────────────────────────────────────── */
footer {
  border-top: 1px solid var(--border);
  padding: 36px 24px;
  text-align: center;
  color: var(--muted);
  font-size: 13px;
  margin-top: 0;
}
footer a { color: var(--text-dim); font-weight: 500; }
footer a:hover { color: var(--text); text-decoration: none; }

/* ── Responsive ───────────────────────────────────────────────── */
@media (max-width: 680px) {
  nav { padding: 0 20px; }
  .hero { padding: 72px 20px 56px; }
  .cta-card { padding: 40px 24px; }
  .steps { grid-template-columns: 1fr; gap: 36px; }
  .steps::before { display: none; }
  .mockup-subtitles { padding: 16px 16px 14px; }
  .pricing-card { padding: 28px; }
  .trust-item:not(:last-child) { border-right: none; }
}
