:root {
  --navy: #1A2E4A;
  --navy-soft: #2a3f5f;
  --blue: #2979FF;
  --blue-dark: #1e5fcc;
  --blue-soft: #E7F1FF;
  --bg: #F5F7FB;
  --card: #FFFFFF;
  --text: #1A2E4A;
  --text-muted: #5B6B82;
  --border: #E2E7EF;
  --tip-bg: #FFF8E6;
  --tip-border: #F5C842;
  --tip-label: #8B6914;
  --shadow: 0 2px 12px rgba(26, 46, 74, 0.06);
}

* { box-sizing: border-box; }

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

html, body {
  margin: 0;
  padding: 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

body {
  display: flex;
  flex-direction: column;
}

/* Header */
.site-header {
  background: var(--navy);
  color: #fff;
  position: sticky;
  top: 0;
  z-index: 10;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  padding-top: env(safe-area-inset-top);
}

.header-inner {
  max-width: 720px;
  margin: 0 auto;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.logo {
  height: 32px;
  width: auto;
  display: block;
}

/* Seven languages no longer fit next to the logo on a phone: the switch is
   274px wide and a 380px screen leaves about 352px once the logo is placed.
   Let the switch drop onto its own line rather than squash the logo, which
   flex would otherwise shrink out of proportion. */
.header-inner { flex-wrap: wrap; }
.logo { flex: none; }

.lang-switch {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  margin-left: auto;
  gap: 2px;
  background: rgba(255,255,255,0.12);
  border-radius: 8px;
  padding: 3px;
}

.lang-btn {
  background: transparent;
  border: none;
  color: rgba(255,255,255,0.75);
  padding: 6px 10px;
  font-size: 13px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  font-family: inherit;
  min-width: 34px;
}

.lang-btn:hover { color: #fff; }
.lang-btn.active { background: #fff; color: var(--navy); }

/* Page */
.page {
  flex: 1;
  width: 100%;
  max-width: 720px;
  margin: 0 auto;
  padding: 28px 20px 40px;
}

/* Hero */
.hero {
  margin-bottom: 28px;
}

.hero-title {
  font-size: 28px;
  font-weight: 700;
  color: var(--navy);
  margin: 0 0 6px;
  letter-spacing: -0.3px;
}

.hero-subtitle {
  font-size: 15px;
  font-weight: 600;
  color: var(--blue);
  margin: 0 0 14px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
}

.hero-intro {
  font-size: 16px;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0;
}

/* Sections */
.sections {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.manual-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 20px 18px;
  box-shadow: var(--shadow);
}

.section-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 10px;
}

.section-num {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  background: var(--navy);
  color: #fff;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  font-weight: 700;
}

.section-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--navy);
  margin: 0;
  line-height: 1.3;
}

.section-body {
  font-size: 15px;
  line-height: 1.55;
  color: var(--text);
  margin: 0 0 0;
}

.section-body p { margin: 0 0 8px; }
.section-body p:last-child { margin-bottom: 0; }

.section-body a {
  color: var(--blue);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid rgba(41, 121, 255, 0.3);
  transition: border-color 0.15s;
}
.section-body a:hover {
  border-bottom-color: var(--blue);
}

.section-body strong {
  color: var(--navy);
  font-weight: 600;
}

.section-bullets {
  list-style: none;
  padding: 0;
  margin: 10px 0 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.section-bullets li {
  position: relative;
  padding-left: 18px;
  font-size: 15px;
  line-height: 1.5;
  color: var(--text);
}

.section-bullets li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: 9px;
  width: 6px;
  height: 6px;
  background: var(--blue);
  border-radius: 50%;
}

.tip {
  margin-top: 14px;
  background: var(--tip-bg);
  border-left: 3px solid var(--tip-border);
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 14px;
  line-height: 1.5;
  color: var(--text);
}

.tip-label {
  display: block;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--tip-label);
  margin-bottom: 2px;
}

/* Support card */
.support-card {
  background: var(--navy);
  color: #fff;
  border-radius: 14px;
  padding: 22px 20px;
  margin-top: 28px;
  text-align: center;
}

.support-title {
  font-size: 16px;
  font-weight: 700;
  margin-bottom: 6px;
}

.support-body {
  font-size: 14px;
  line-height: 1.5;
  color: rgba(255,255,255,0.85);
}

/* Footer */
.site-footer {
  padding: 18px 20px calc(18px + env(safe-area-inset-bottom));
  font-size: 12px;
  color: var(--text-muted);
  text-align: center;
}

/* Tablet / desktop */
@media (min-width: 640px) {
  .hero-title { font-size: 32px; }
  .manual-section { padding: 24px 26px 22px; }
  .section-title { font-size: 18px; }
  .section-body, .section-bullets li { font-size: 15px; }
}

/* Small phones */
@media (max-width: 380px) {
  .header-inner { padding: 12px 14px; }
  .page { padding: 22px 14px 32px; }
  .hero-title { font-size: 24px; }
  .manual-section { padding: 18px 16px; border-radius: 12px; }
  .section-num { width: 28px; height: 28px; font-size: 13px; }
  .section-title { font-size: 16px; }
}
