/* ============================================================
   ChainMail Website — Styles
   Brand: Teal #0D9488, Inter font, clean & professional
   ============================================================ */

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #1a1a1a;
  background: #ffffff;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: #0D9488;
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: #0F766E;
}

img {
  display: block;
  max-width: 100%;
}

/* --- Layout --- */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px;
}

.container--narrow {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Header / Nav --- */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #e8e8e8;
}

.header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-size: 18px;
  color: #1a1a1a;
}

.logo img {
  width: 32px;
  height: 32px;
  border-radius: 6px;
}

.nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.nav a {
  color: #555;
  font-size: 14px;
  font-weight: 500;
  transition: color 0.15s ease;
}

.nav a:hover {
  color: #1a1a1a;
}

.nav .btn--sm {
  font-size: 14px;
  padding: 8px 20px;
}

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: #1a1a1a;
  margin: 5px 0;
  border-radius: 1px;
  transition: all 0.2s ease;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 15px;
  cursor: pointer;
  border: none;
  transition: all 0.15s ease;
  text-decoration: none;
}

.btn--primary {
  background: #0D9488;
  color: #fff;
}

.btn--primary:hover {
  background: #0F766E;
  color: #fff;
}

.btn--secondary {
  background: transparent;
  color: #0D9488;
  border: 1.5px solid #0D9488;
}

.btn--secondary:hover {
  background: #0D9488;
  color: #fff;
}

.btn--dark {
  background: #1a1a1e;
  color: #fff;
}

.btn--dark:hover {
  background: #2c2c30;
  color: #fff;
}

/* --- Hero --- */
.hero {
  padding: 140px 0 80px;
  text-align: center;
  background: linear-gradient(180deg, #f0fdfa 0%, #ffffff 100%);
}

.hero__badge {
  display: inline-block;
  padding: 6px 16px;
  background: #ccfbf1;
  color: #0D9488;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 24px;
  letter-spacing: 0.02em;
}

.hero h1 {
  font-size: 48px;
  font-weight: 700;
  line-height: 1.15;
  color: #1a1a1a;
  margin-bottom: 20px;
  letter-spacing: -0.02em;
}

.hero h1 span {
  color: #0D9488;
}

.hero__subtitle {
  font-size: 19px;
  color: #555;
  max-width: 560px;
  margin: 0 auto 36px;
  line-height: 1.6;
}

.hero__actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

.hero__note {
  margin-top: 16px;
  font-size: 13px;
  color: #888;
}

/* --- Features --- */
.features {
  padding: 80px 0;
}

.features__header {
  text-align: center;
  margin-bottom: 56px;
}

.features__header h2 {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

.features__header p {
  font-size: 17px;
  color: #555;
  max-width: 520px;
  margin: 0 auto;
}

.features__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px;
}

.feature-card {
  padding: 28px;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.feature-card:hover {
  border-color: #d0d0d0;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.feature-card__icon {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: #f0fdfa;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
  color: #0D9488;
  font-size: 22px;
}

.feature-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: #555;
  line-height: 1.6;
}

/* --- Screenshot / Preview --- */
.preview {
  padding: 40px 0 80px;
  text-align: center;
}

.preview__image {
  max-width: 960px;
  margin: 0 auto;
  border-radius: 12px;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
  border: 1px solid #e8e8e8;
  overflow: hidden;
}

.preview__image img {
  width: 100%;
}

/* --- How It Works --- */
.how-it-works {
  padding: 80px 0;
  background: #fafafa;
}

.how-it-works__header {
  text-align: center;
  margin-bottom: 56px;
}

.how-it-works__header h2 {
  font-size: 32px;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 12px;
}

.how-it-works__header p {
  font-size: 17px;
  color: #555;
}

.steps {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 40px;
  text-align: center;
}

.step__number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: #0D9488;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 18px;
  margin: 0 auto 16px;
}

.step h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
}

.step p {
  font-size: 14px;
  color: #555;
  line-height: 1.6;
}

/* --- CTA Section --- */
.cta {
  padding: 80px 0;
  text-align: center;
}

.cta__box {
  background: linear-gradient(135deg, #0D9488, #0F766E);
  border-radius: 16px;
  padding: 56px 40px;
  color: #fff;
}

.cta__box h2 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 12px;
}

.cta__box p {
  font-size: 17px;
  opacity: 0.9;
  margin-bottom: 28px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

.cta__box .btn--primary {
  background: #fff;
  color: #0D9488;
}

.cta__box .btn--primary:hover {
  background: #f0fdfa;
}

/* --- Footer --- */
.footer {
  padding: 48px 0;
  border-top: 1px solid #e8e8e8;
}

.footer .container {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 32px;
}

.footer__brand {
  max-width: 280px;
}

.footer__brand .logo {
  margin-bottom: 12px;
}

.footer__brand p {
  font-size: 13px;
  color: #888;
  line-height: 1.6;
}

.footer__links {
  display: flex;
  gap: 48px;
}

.footer__col h4 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #888;
  margin-bottom: 12px;
}

.footer__col a {
  display: block;
  font-size: 14px;
  color: #555;
  padding: 4px 0;
}

.footer__col a:hover {
  color: #0D9488;
}

.footer__bottom {
  padding-top: 24px;
  margin-top: 24px;
  border-top: 1px solid #e8e8e8;
  font-size: 13px;
  color: #888;
  text-align: center;
}

/* --- Legal Pages (Privacy, Terms, Support) --- */
.legal {
  padding: 120px 0 80px;
}

.legal h1 {
  font-size: 36px;
  font-weight: 700;
  margin-bottom: 8px;
  letter-spacing: -0.01em;
}

.legal__updated {
  font-size: 14px;
  color: #888;
  margin-bottom: 40px;
}

.legal h2 {
  font-size: 22px;
  font-weight: 600;
  margin-top: 40px;
  margin-bottom: 12px;
  color: #1a1a1a;
}

.legal h3 {
  font-size: 17px;
  font-weight: 600;
  margin-top: 28px;
  margin-bottom: 8px;
}

.legal p {
  margin-bottom: 16px;
  color: #333;
  line-height: 1.7;
}

.legal ul, .legal ol {
  margin-bottom: 16px;
  padding-left: 24px;
}

.legal li {
  list-style: disc;
  margin-bottom: 8px;
  color: #333;
  line-height: 1.7;
}

.legal ol li {
  list-style: decimal;
}

.legal strong {
  color: #1a1a1a;
}

.legal a {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.legal .scope-table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0 24px;
  font-size: 14px;
}

.legal .scope-table th,
.legal .scope-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid #e8e8e8;
}

.legal .scope-table th {
  font-weight: 600;
  background: #fafafa;
  color: #555;
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.legal .scope-table td {
  color: #333;
}

.legal .scope-table code {
  font-size: 12px;
  background: #f5f5f5;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: 'SF Mono', 'Fira Code', monospace;
}

/* --- Support Page --- */
.support-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin: 32px 0;
}

.support-card {
  padding: 28px;
  border-radius: 12px;
  border: 1px solid #e8e8e8;
}

.support-card h3 {
  margin-top: 0;
  margin-bottom: 8px;
}

.support-card p {
  margin-bottom: 12px;
}

.faq {
  margin-top: 48px;
}

.faq h2 {
  margin-bottom: 24px;
}

.faq-item {
  border-bottom: 1px solid #e8e8e8;
  padding: 20px 0;
}

.faq-item h3 {
  margin-top: 0;
  font-size: 16px;
  cursor: default;
}

.faq-item p {
  margin-top: 8px;
  margin-bottom: 0;
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .hero {
    padding: 110px 0 60px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero__subtitle {
    font-size: 16px;
  }

  .features__grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 32px;
  }

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

  .nav {
    display: none;
  }

  .nav.active {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #fff;
    border-bottom: 1px solid #e8e8e8;
    padding: 16px 24px;
    gap: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
  }

  .nav-toggle {
    display: block;
  }

  .footer .container {
    flex-direction: column;
  }

  .footer__links {
    gap: 32px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 28px;
  }

  .hero__actions {
    flex-direction: column;
    align-items: center;
  }

  .cta__box {
    padding: 40px 24px;
  }
}
