/* ============================================================
   HuTuDan — Free Online File Converter
   Design: Refined Industrial with Warm Geometric Accents
   ============================================================ */

/* --- Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700&family=DM+Sans:opsz,wght@9..40,400;9..40,500;9..40,600;9..40,700&display=swap');

/* --- CSS Custom Properties --- */
:root {
  --bg-primary: #faf7f2;
  --bg-secondary: #f2ede6;
  --bg-tertiary: #ebe5dc;
  --bg-dark: #14161a;
  --bg-dark-alt: #1c1f24;
  --bg-card: #ffffff;
  --text-primary: #14161a;
  --text-secondary: #5a5d63;
  --text-tertiary: #94979d;
  --text-inverse: #f5f0ea;
  --text-inverse-muted: #a0a3a8;
  --accent: #e87840;
  --accent-hover: #d0652e;
  --accent-light: #fef3eb;
  --accent-soft: #fce8d8;
  --secondary-accent: #3d8b6e;
  --secondary-light: #e8f5ef;
  --border: #e4ded6;
  --border-light: #f0ebe3;
  --shadow-xs: 0 1px 2px rgba(20,22,26,0.04);
  --shadow-sm: 0 2px 8px rgba(20,22,26,0.06);
  --shadow-md: 0 4px 20px rgba(20,22,26,0.08);
  --shadow-lg: 0 8px 40px rgba(20,22,26,0.12);
  --shadow-xl: 0 16px 64px rgba(20,22,26,0.16);
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-xl: 30px;
  --radius-full: 9999px;
  --font-display: 'Fraunces', Georgia, 'Times New Roman', serif;
  --font-body: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --transition-fast: 0.18s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 0.45s cubic-bezier(0.4, 0, 0.2, 1);
  --max-width: 1240px;
  --nav-height: 72px;
}

/* --- Reset & Base --- */
*,
*::before,
*::after { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

::selection {
  background: var(--accent-soft);
  color: var(--accent-hover);
}

/* --- Focus --- */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}
:focus:not(:focus-visible) { outline: none; }

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.15;
  letter-spacing: -0.02em;
}
h1 { font-size: clamp(2.5rem, 5vw, 3.8rem); }
h2 { font-size: clamp(1.8rem, 3.5vw, 2.6rem); }
h3 { font-size: clamp(1.25rem, 2.2vw, 1.6rem); }

a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
button { cursor: pointer; font-family: inherit; border: none; background: none; }

/* ============================================================
   NAVIGATION
   ============================================================ */
.nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 1000;
  height: var(--nav-height);
  background: rgba(250,247,242,0.82);
  backdrop-filter: blur(18px) saturate(1.4);
  -webkit-backdrop-filter: blur(18px) saturate(1.4);
  border-bottom: 1px solid var(--border);
  transition: background var(--transition-base), box-shadow var(--transition-base);
}
.nav.scrolled {
  background: rgba(250,247,242,0.95);
  box-shadow: var(--shadow-sm);
}

.nav-inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 28px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.03em;
}
.nav-brand-icon {
  width: 30px; height: 41px;
  flex-shrink: 0;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
  list-style: none;
}
.nav-links a {
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 0.92rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: color var(--transition-fast), background var(--transition-fast);
}
.nav-links a:hover,
.nav-links a.active {
  color: var(--text-primary);
  background: var(--bg-secondary);
}

/* Language Switcher */
.lang-switch {
  position: relative;
  margin-left: 12px;
}
.lang-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-secondary);
  border: 1px solid var(--border);
  background: var(--bg-card);
  transition: all var(--transition-fast);
}
.lang-btn:hover { border-color: var(--accent); color: var(--text-primary); }
.lang-btn .arrow { font-size: 0.65rem; transition: transform var(--transition-fast); }
.lang-btn.open .arrow { transform: rotate(180deg); }

.lang-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 160px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  opacity: 0; visibility: hidden;
  transform: translateY(-8px);
  transition: all var(--transition-base);
  z-index: 100;
  list-style: none;
}
.lang-dropdown.show {
  opacity: 1; visibility: visible;
  transform: translateY(0);
}
.lang-dropdown li button {
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  color: var(--text-secondary);
  transition: all var(--transition-fast);
  display: flex; align-items: center; gap: 8px;
}
.lang-dropdown li button:hover { background: var(--bg-secondary); color: var(--text-primary); }
.lang-dropdown li button.active { color: var(--accent); font-weight: 600; background: var(--accent-light); }
.lang-check { margin-left: auto; font-size: 0.8rem; color: var(--accent); opacity: 0; }
.lang-dropdown li button.active .lang-check { opacity: 1; }

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  border-radius: var(--radius-sm);
}
.nav-toggle span {
  display: block;
  width: 22px; height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform var(--transition-base), opacity var(--transition-base);
}
.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 SECTION
   ============================================================ */
.hero {
  padding: calc(var(--nav-height) + 60px) 28px 80px;
  text-align: center;
  position: relative;
  overflow: hidden;
}

/* Decorative background shapes */
.hero::before {
  content: '';
  position: absolute;
  top: -180px; left: 50%;
  transform: translateX(-50%);
  width: 800px; height: 800px;
  background: radial-gradient(circle at 50% 40%, rgba(232,120,64,0.07) 0%, transparent 70%);
  pointer-events: none;
}
.hero::after {
  content: '';
  position: absolute;
  bottom: -120px; left: -200px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(61,139,110,0.05) 0%, transparent 70%);
  pointer-events: none;
}

.hero-content { position: relative; z-index: 1; }
.hero h1 { margin-bottom: 16px; }
.hero-subtitle {
  font-size: 1.12rem;
  color: var(--text-secondary);
  max-width: 640px;
  margin: 0 auto 48px;
  line-height: 1.7;
}

/* Trust Badges */
.hero-badges {
  display: flex;
  justify-content: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 48px;
}
.badge {
  display: flex; align-items: center; gap: 7px;
  padding: 8px 18px;
  border-radius: var(--radius-full);
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-secondary);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
}
.badge-icon {
  width: 18px; height: 18px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-size: 0.7rem;
}
.badge-icon.green { background: var(--secondary-light); color: var(--secondary-accent); }
.badge-icon.amber { background: var(--accent-light); color: var(--accent); }

/* Upload Zone */
.upload-zone {
  max-width: 680px;
  margin: 0 auto 32px;
  padding: 56px 40px;
  border: 2px dashed var(--border);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  cursor: pointer;
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}
.upload-zone::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 50%, rgba(232,120,64,0.04) 0%, transparent 70%);
  opacity: 0;
  transition: opacity var(--transition-base);
}
.upload-zone:hover,
.upload-zone.drag-over {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}
.upload-zone:hover::before,
.upload-zone.drag-over::before { opacity: 1; }

.upload-icon {
  width: 64px; height: 64px;
  margin: 0 auto 20px;
  background: var(--accent-light);
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  transition: transform var(--transition-base), background var(--transition-base);
}
.upload-zone:hover .upload-icon,
.upload-zone.drag-over .upload-icon {
  transform: scale(1.1);
  background: var(--accent-soft);
}
.upload-icon svg { width: 28px; height: 28px; color: var(--accent); }

.upload-text {
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 4px;
  position: relative; z-index: 1;
}
.upload-hint {
  font-size: 0.88rem;
  color: var(--text-tertiary);
  position: relative; z-index: 1;
}
.upload-or {
  font-size: 0.88rem;
  color: var(--text-tertiary);
  margin: 16px 0;
  display: flex; align-items: center; gap: 12px;
  position: relative; z-index: 1;
}
.upload-or::before,
.upload-or::after {
  content: '';
  flex: 1; height: 1px;
  background: var(--border);
}
.upload-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 4px 16px rgba(232,120,64,0.3);
  transition: all var(--transition-base);
  position: relative; z-index: 1;
}
.upload-btn:hover {
  background: var(--accent-hover);
  box-shadow: 0 6px 24px rgba(232,120,64,0.4);
  transform: translateY(-1px);
}
.upload-btn:active { transform: translateY(0); }

/* File selected state */
.upload-file-info {
  display: none;
  align-items: center; gap: 16px;
  padding: 16px 24px;
  background: var(--bg-secondary);
  border-radius: var(--radius-md);
  margin-top: 24px;
  text-align: left;
}
.upload-file-info.show { display: flex; }
.file-icon-box {
  width: 48px; height: 48px;
  border-radius: var(--radius-sm);
  background: var(--accent-light);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.file-icon-box svg { width: 22px; height: 22px; color: var(--accent); }
.file-detail { flex: 1; min-width: 0; }
.file-name {
  font-weight: 600; font-size: 0.95rem;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.file-size { font-size: 0.8rem; color: var(--text-tertiary); }
.file-remove {
  width: 32px; height: 32px;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--text-tertiary);
  font-size: 1.1rem;
  transition: all var(--transition-fast);
}
.file-remove:hover { background: #fee; color: #e04040; }

/* Format Selector */
.format-select-row {
  display: none;
  align-items: center; justify-content: center; gap: 16px;
  margin-top: 24px;
  flex-wrap: wrap;
}
.format-select-row.show { display: flex; }
.format-select {
  padding: 12px 20px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  font-size: 0.92rem;
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg-card);
  min-width: 180px;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2394979d'%3E%3Cpath d='M6 8L1 3h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 16px center;
  padding-right: 40px;
  transition: border-color var(--transition-fast);
}
.format-select:focus { border-color: var(--accent); }

.convert-btn-big {
  padding: 12px 36px;
  border-radius: var(--radius-full);
  font-size: 1rem;
  font-weight: 600;
  color: #fff;
  background: var(--accent);
  box-shadow: 0 4px 16px rgba(232,120,64,0.3);
  transition: all var(--transition-base);
  white-space: nowrap;
}
.convert-btn-big:hover {
  background: var(--accent-hover);
  box-shadow: 0 6px 24px rgba(232,120,64,0.4);
  transform: translateY(-1px);
}
.convert-btn-big:disabled {
  opacity: 0.5; cursor: not-allowed;
  transform: none;
  box-shadow: 0 2px 8px rgba(232,120,64,0.15);
}

/* Processing state */
.upload-processing {
  display: none;
  align-items: center; justify-content: center; gap: 12px;
  margin-top: 24px;
  padding: 16px 24px;
  background: var(--accent-light);
  border-radius: var(--radius-md);
  font-weight: 500;
  color: var(--accent-hover);
}
.upload-processing.show { display: flex; }
.processing-spinner {
  width: 20px; height: 20px;
  border: 2.5px solid var(--accent-soft);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 0.7s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

/* Download state */
.upload-done {
  display: none;
  align-items: center; justify-content: center; gap: 12px;
  margin-top: 24px;
}
.upload-done.show { display: flex; }
.download-btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 28px;
  border-radius: var(--radius-full);
  font-size: 0.95rem;
  font-weight: 600;
  color: #fff;
  background: var(--secondary-accent);
  box-shadow: 0 4px 16px rgba(61,139,110,0.3);
  transition: all var(--transition-base);
}
.download-btn:hover {
  filter: brightness(1.1);
  transform: translateY(-1px);
}

/* ============================================================
   SECTIONS
   ============================================================ */
.section {
  padding: 80px 28px;
  position: relative;
}
.section-dark {
  background: var(--bg-dark);
  color: var(--text-inverse);
}
.section-header {
  text-align: center;
  margin-bottom: 56px;
}
.section-header h2 { margin-bottom: 12px; }
.section-header p {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 560px;
  margin: 0 auto;
}
.section-dark .section-header p { color: var(--text-inverse-muted); }

.section-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

/* ============================================================
   POPULAR CONVERSIONS
   ============================================================ */
.popular-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 14px;
}
.tool-card {
  display: flex; align-items: center; gap: 12px;
  padding: 16px 20px;
  border-radius: var(--radius-md);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
}
.tool-card::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 60px; height: 60px;
  background: radial-gradient(circle at 100% 0%, rgba(232,120,64,0.06) 0%, transparent 70%);
  pointer-events: none;
}
.tool-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--accent);
}
.tool-card-icon {
  width: 42px; height: 42px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.78rem;
  font-weight: 700;
  flex-shrink: 0;
}
.tool-card-icon.pdf { background: #fdecea; color: #d93025; }
.tool-card-icon.doc { background: #e8f0fe; color: #1a73e8; }
.tool-card-icon.img { background: #fef0e5; color: #e87840; }
.tool-card-icon.vid { background: #ede7f6; color: #7c4dff; }
.tool-card-icon.aud { background: #e8f5ef; color: #3d8b6e; }
.tool-card-icon.arc { background: #fce4ec; color: #c62828; }
.tool-card-icon.comp { background: #fff3e0; color: #e65100; }
.tool-card-icon.ebk { background: #e3f2fd; color: #1565c0; }

.tool-card-label {
  font-size: 0.92rem;
  font-weight: 500;
  line-height: 1.3;
  min-width: 0;
}

/* ============================================================
   TOOL CATEGORIES
   ============================================================ */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 18px;
}
.cat-card {
  padding: 28px 24px;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
  transition: all var(--transition-base);
  position: relative;
  overflow: hidden;
  cursor: pointer;
}
.cat-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
  border-color: transparent;
}
.cat-card:nth-child(1):hover { border-color: #d93025; box-shadow: 0 6px 24px rgba(217,48,37,0.12); }
.cat-card:nth-child(2):hover { border-color: #1a73e8; box-shadow: 0 6px 24px rgba(26,115,232,0.12); }
.cat-card:nth-child(3):hover { border-color: #e87840; box-shadow: 0 6px 24px rgba(232,120,64,0.12); }
.cat-card:nth-child(4):hover { border-color: #7c4dff; box-shadow: 0 6px 24px rgba(124,77,255,0.12); }
.cat-card:nth-child(5):hover { border-color: #3d8b6e; box-shadow: 0 6px 24px rgba(61,139,110,0.12); }
.cat-card:nth-child(6):hover { border-color: #e65100; box-shadow: 0 6px 24px rgba(230,81,0,0.12); }
.cat-card:nth-child(7):hover { border-color: #f4a261; box-shadow: 0 6px 24px rgba(244,162,97,0.12); }
.cat-card:nth-child(8):hover { border-color: #c62828; box-shadow: 0 6px 24px rgba(198,40,40,0.12); }
.cat-card:nth-child(9):hover { border-color: #00acc1; box-shadow: 0 6px 24px rgba(0,172,193,0.12); }
.cat-card:nth-child(10):hover { border-color: #7b1fa2; box-shadow: 0 6px 24px rgba(123,31,162,0.12); }
.cat-card:nth-child(11):hover { border-color: #546e7a; box-shadow: 0 6px 24px rgba(84,110,122,0.12); }

.cat-card::before {
  content: '';
  position: absolute;
  top: -40px; right: -40px;
  width: 120px; height: 120px;
  border-radius: 50%;
  opacity: 0.06;
  transition: opacity var(--transition-base), transform var(--transition-base);
}
.cat-card:nth-child(1)::before { background: #d93025; }
.cat-card:nth-child(2)::before { background: #1a73e8; }
.cat-card:nth-child(3)::before { background: #e87840; }
.cat-card:nth-child(4)::before { background: #7c4dff; }
.cat-card:nth-child(5)::before { background: #3d8b6e; }
.cat-card:nth-child(6)::before { background: #e65100; }
.cat-card:nth-child(7)::before { background: #f4a261; }
.cat-card:nth-child(8)::before { background: #c62828; }
.cat-card:nth-child(9)::before { background: #00acc1; }
.cat-card:nth-child(10)::before { background: #7b1fa2; }
.cat-card:nth-child(11)::before { background: #546e7a; }
.cat-card:hover::before { opacity: 0.1; transform: scale(1.2); }

.cat-card-icon-large {
  width: 52px; height: 52px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 16px;
  font-size: 1.4rem;
  position: relative; z-index: 1;
}
.cat-card:nth-child(1) .cat-card-icon-large { background: #fdecea; color: #d93025; }
.cat-card:nth-child(2) .cat-card-icon-large { background: #e8f0fe; color: #1a73e8; }
.cat-card:nth-child(3) .cat-card-icon-large { background: #fef0e5; color: #e87840; }
.cat-card:nth-child(4) .cat-card-icon-large { background: #ede7f6; color: #7c4dff; }
.cat-card:nth-child(5) .cat-card-icon-large { background: #e8f5ef; color: #3d8b6e; }
.cat-card:nth-child(6) .cat-card-icon-large { background: #fff3e0; color: #e65100; }
.cat-card:nth-child(7) .cat-card-icon-large { background: #fef3e0; color: #e87840; }
.cat-card:nth-child(8) .cat-card-icon-large { background: #fce4ec; color: #c62828; }
.cat-card:nth-child(9) .cat-card-icon-large { background: #e0f7fa; color: #00acc1; }
.cat-card:nth-child(10) .cat-card-icon-large { background: #f3e5f5; color: #7b1fa2; }
.cat-card:nth-child(11) .cat-card-icon-large { background: #eceff1; color: #546e7a; }

.cat-card-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 6px;
  position: relative; z-index: 1;
}
.cat-card-count {
  font-size: 0.84rem;
  color: var(--text-tertiary);
  position: relative; z-index: 1;
}

/* ============================================================
   FEATURES
   ============================================================ */
.features-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 24px;
}
.feature-card {
  padding: 32px 28px;
  border-radius: var(--radius-lg);
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  transition: all var(--transition-base);
}
.feature-card:hover {
  background: rgba(255,255,255,0.07);
  transform: translateY(-2px);
}
.feature-icon {
  width: 48px; height: 48px;
  border-radius: var(--radius-md);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 18px;
  font-size: 1.3rem;
}
.feature-card:nth-child(1) .feature-icon { background: rgba(232,120,64,0.15); color: var(--accent); }
.feature-card:nth-child(2) .feature-icon { background: rgba(61,139,110,0.15); color: var(--secondary-accent); }
.feature-card:nth-child(3) .feature-icon { background: rgba(124,77,255,0.15); color: #9c7cf4; }
.feature-card:nth-child(4) .feature-icon { background: rgba(26,115,232,0.15); color: #5a9cf6; }
.feature-card:nth-child(5) .feature-icon { background: rgba(217,48,37,0.15); color: #e8716a; }
.feature-card:nth-child(6) .feature-icon { background: rgba(0,172,193,0.15); color: #4dd0e1; }

.feature-card h3 {
  font-size: 1.08rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.feature-card p {
  font-size: 0.92rem;
  color: var(--text-inverse-muted);
  line-height: 1.6;
}

/* ============================================================
   HELP CENTER
   ============================================================ */
.help-subtitle {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 24px;
  text-align: center;
}

/* Usage Guide Steps */
.help-steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 64px;
  position: relative;
}
.help-step {
  text-align: center;
  padding: 28px 20px;
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  box-shadow: var(--shadow-xs);
  position: relative;
  transition: all var(--transition-base);
}
.help-step:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}
.help-step-num {
  width: 40px; height: 40px;
  margin: 0 auto 14px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-size: 1.1rem;
  font-weight: 700;
}
.help-step h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
}
.help-step p {
  font-size: 0.88rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* Step connector lines (desktop only) */
@media (min-width: 769px) {
  .help-steps::before {
    content: '';
    position: absolute;
    top: 48px; left: 0; right: 0;
    height: 2px;
    background: linear-gradient(to right, var(--accent) 0%, var(--accent) 70%, transparent 100%);
    z-index: 0;
    opacity: 0.2;
  }
}

/* FAQ Accordion */
.help-faq {
  margin-bottom: 64px;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}
.faq-item {
  border: 1px solid var(--border-light);
  border-radius: var(--radius-md);
  margin-bottom: 10px;
  background: var(--bg-card);
  overflow: hidden;
  transition: all var(--transition-base);
}
.faq-item:hover { border-color: var(--border); }
.faq-item.open { border-color: var(--accent); box-shadow: var(--shadow-sm); }

.faq-question {
  width: 100%;
  padding: 18px 24px;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px;
  font-size: 0.97rem;
  font-weight: 500;
  color: var(--text-primary);
  text-align: left;
  transition: color var(--transition-fast);
}
.faq-question:hover { color: var(--accent); }
.faq-arrow {
  flex-shrink: 0;
  width: 24px; height: 24px;
  border-radius: 50%;
  background: var(--bg-secondary);
  display: flex; align-items: center; justify-content: center;
  font-size: 0.65rem;
  color: var(--text-tertiary);
  transition: all var(--transition-base);
}
.faq-item.open .faq-arrow {
  background: var(--accent-light);
  color: var(--accent);
  transform: rotate(180deg);
}
.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s ease, padding 0.35s ease;
}
.faq-item.open .faq-answer { max-height: 200px; }
.faq-answer p {
  padding: 0 24px 18px;
  font-size: 0.92rem;
  color: var(--text-secondary);
  line-height: 1.7;
}

/* Format Reference Table */
.help-formats { max-width: 800px; margin-left: auto; margin-right: auto; }
.format-table-wrap {
  overflow-x: auto;
  border: 1px solid var(--border-light);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  box-shadow: var(--shadow-sm);
}
.format-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.9rem;
}
.format-table th {
  text-align: left;
  padding: 14px 20px;
  font-weight: 600;
  color: var(--text-primary);
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  font-size: 0.84rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}
.format-table td {
  padding: 12px 20px;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-light);
}
.format-table tr:last-child td { border-bottom: none; }
.format-table tr:hover td { background: var(--bg-primary); }
.format-tag {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 500;
  background: var(--accent-light);
  color: var(--accent);
}

/* ============================================================
   SEARCH BAR
   ============================================================ */
.search-bar {
  max-width: 480px;
  margin: 0 auto 48px;
  position: relative;
}
.search-bar input {
  width: 100%;
  padding: 14px 48px 14px 20px;
  border-radius: var(--radius-full);
  border: 1px solid var(--border);
  font-size: 0.95rem;
  font-family: var(--font-body);
  color: var(--text-primary);
  background: var(--bg-card);
  transition: all var(--transition-base);
  box-shadow: var(--shadow-xs);
}
.search-bar input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,120,64,0.12);
}
.search-bar input::placeholder { color: var(--text-tertiary); }
.search-icon-btn {
  position: absolute;
  right: 14px; top: 50%;
  transform: translateY(-50%);
  color: var(--text-tertiary);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px; height: 32px;
  border-radius: 50%;
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer {
  background: var(--bg-dark-alt);
  color: var(--text-inverse-muted);
  padding: 64px 28px 40px;
  border-top: 1px solid rgba(255,255,255,0.06);
}
.footer-inner {
  max-width: var(--max-width);
  margin: 0 auto;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.5fr 1fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-brand h3 {
  color: var(--text-inverse);
  font-size: 1.3rem;
  margin-bottom: 12px;
}
.footer-brand p {
  font-size: 0.9rem;
  line-height: 1.7;
}
.footer-col h4 {
  color: var(--text-inverse);
  font-size: 0.88rem;
  font-weight: 600;
  margin-bottom: 16px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.footer-col ul { list-style: none; }
.footer-col ul li { margin-bottom: 10px; }
.footer-col ul li a {
  font-size: 0.9rem;
  transition: color var(--transition-fast);
}
.footer-col ul li a:hover { color: var(--accent); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 28px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 0.84rem;
}
.footer-contact {
  color: rgba(255,255,255,0.55);
  font-size: 0.82rem;
  line-height: 1.6;
}
.footer-contact::before { content: "✉ "; opacity: 0.5; }
.footer-bottom-links {
  display: flex; gap: 24px;
}
.footer-bottom-links a { transition: color var(--transition-fast); }
.footer-bottom-links a:hover { color: var(--text-inverse); }

/* ============================================================
   BACK TO TOP
   ============================================================ */
.back-top {
  position: fixed;
  bottom: 28px; right: 28px;
  width: 44px; height: 44px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md);
  opacity: 0; visibility: hidden;
  transform: translateY(12px);
  transition: all var(--transition-base);
  z-index: 900;
  font-size: 1.1rem;
}
.back-top.show {
  opacity: 1; visibility: visible;
  transform: translateY(0);
}
.back-top:hover { background: var(--accent-hover); transform: translateY(-2px); }

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 960px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-height);
    left: 0; right: 0;
    background: var(--bg-card);
    border-bottom: 1px solid var(--border);
    padding: 16px 28px;
    gap: 4px;
    box-shadow: var(--shadow-md);
  }
  .nav-toggle { display: flex; }
  .lang-switch { margin-left: auto; margin-right: 12px; }

  .hero { padding: calc(var(--nav-height) + 36px) 20px 48px; }
  .hero-badges { gap: 8px; }
  .badge { padding: 6px 14px; font-size: 0.8rem; }
  .upload-zone { padding: 40px 24px; }
  
  .popular-grid {
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 10px;
  }
  .tool-card { padding: 14px 16px; gap: 10px; }
  .tool-card-label { font-size: 0.84rem; }

  .cat-grid { grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
  .cat-card { padding: 22px 18px; }

  .features-grid { grid-template-columns: 1fr; }

  .help-steps { grid-template-columns: 1fr 1fr; gap: 14px; }
  .help-steps::before { display: none; }
  .help-step { padding: 22px 16px; }
  .format-table th,
  .format-table td { padding: 10px 14px; font-size: 0.82rem; }

  .section { padding: 56px 20px; }
  .section-header { margin-bottom: 40px; }

  .footer-grid { grid-template-columns: 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }

  .format-select-row { flex-direction: column; align-items: stretch; }
  .format-select, .convert-btn-big { width: 100%; text-align: center; }
  .convert-btn-big { justify-content: center; display: flex; }

  .back-top { bottom: 20px; right: 20px; width: 40px; height: 40px; }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 2rem; }
  .hero-subtitle { font-size: 0.95rem; }
  .popular-grid { grid-template-columns: 1fr 1fr; }
  .cat-grid { grid-template-columns: 1fr 1fr; }
  .help-steps { grid-template-columns: 1fr; }
  .upload-zone { padding: 32px 20px; }
}

/* ============================================================
   ANIMATIONS
   ============================================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
.anim-up {
  opacity: 0;
  animation: fadeInUp 0.6s ease forwards;
}
.anim-up:nth-child(2) { animation-delay: 0.1s; }
.anim-up:nth-child(3) { animation-delay: 0.2s; }
.anim-up:nth-child(4) { animation-delay: 0.3s; }
.anim-up:nth-child(5) { animation-delay: 0.4s; }
.anim-up:nth-child(6) { animation-delay: 0.5s; }

/* scroll reveal */
.reveal {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ============================================================
   NOISE TEXTURE OVERLAY
   ============================================================ */
.noise {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.015;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}