:root {
  --primary-color: #3f51b5; /* Material Indigo - match about.php */
  --primary-dark: #303f9f;
  --primary-light: #7986cb;
  --secondary-color: #ffc107; /* Material Amber */
  --tertiary-color: #605f48; /* accent used in about.php */
  --text-primary: #212121;
  --text-secondary: #616161;
  --background-color: #f5f7fa;
  --surface-color: #ffffff;
  --border-color: #e0e0e0;
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.07);
  --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
}

body {
  font-family: "Inter", sans-serif;
  background: linear-gradient(180deg, #f6f8fb 0%, #f3f6fa 100%);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Language Switcher inside hero header (top-right) */
.hero-section {
  position: relative;
}

.hero-lang-switch {
  position: absolute;
  top: 18px;
  right: 18px;
  z-index: 50;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  padding: 6px;
  border-radius: 22px;
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(0, 0, 0, 0.06);
  display: flex;
  gap: 6px;
  align-items: center;
}

.hero-lang-switch:hover {
  transform: translateY(-2px);
  transition: transform 0.18s ease;
}

.hero-lang-switch .lang-btn {
  padding: 6px 12px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  background: transparent;
  border: none;
  border-radius: 16px;
  cursor: pointer;
  transition: all 0.15s ease;
  min-width: 44px;
}

.hero-lang-switch .lang-btn:focus {
  outline: 3px solid rgba(63, 81, 181, 0.18);
  outline-offset: 3px;
  box-shadow: 0 2px 6px rgba(63, 81, 181, 0.08);
}

.hero-lang-switch .lang-btn.active {
  background-color: var(--primary-color);
  color: white;
  box-shadow: var(--shadow-sm);
}

/* Hero Section */
.hero-section {
  background: linear-gradient(
    135deg,
    var(--secondary-color) 0%,
    var(--tertiary-color) 100%
  );
  color: white;
  padding: 60px 20px;
  text-align: center;
  margin-bottom: 40px;
}

.hero-section {
  background: linear-gradient(
    135deg,
    var(--secondary-color) 0%,
    var(--tertiary-color) 100%
  );
  color: white;
  padding: 64px 0;
  text-align: left;
  margin-bottom: 36px;
}

.hero-inner {
  width: 100%;
  padding: 0 6vw; /* use viewport padding so content reaches edges on large screens */
  box-sizing: border-box;
  max-width: none;
}

.hero-section h1 {
  color: white;
  font-size: clamp(1.8rem, 3.6vw, 2.6rem);
  font-weight: 700;
  margin: 0 0 12px 0;
}

/* Main Content */
.guide-content {
  width: 100%;
  padding: 28px 6vw 80px 6vw; /* full-bleed layout while keeping breathing room */
  box-sizing: border-box;
}

/* Inner column for long-form readable blocks when needed */
.guide-inner {
  width: 100%;
  max-width: 1400px; /* allow very wide content but cap for readability */
  margin: 0 auto;
}

h2 {
  font-size: 1.75rem;
  color: var(--primary-color);
  margin: 2.5rem 0 1.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--primary-light);
  font-weight: 700;
  display: flex;
  align-items: center;
}

h3 {
  font-size: 1.5rem;
  color: var(--text-primary);
  margin: 2rem 0 1rem;
  font-weight: 600;
}

h4 {
  font-size: 1.25rem;
  color: var(--primary-dark);
  margin: 2rem 0 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
}

.guide-content p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-size: 1rem;
  line-height: 1.7;
}

/* Table of Contents */
.toc {
  background: var(--surface-color);
  border-radius: 12px;
  padding: 24px 28px;
  margin: 1.5rem 0;
  box-shadow: 0 8px 18px rgba(15, 23, 42, 0.06);
  border: 1px solid rgba(16, 24, 40, 0.04);
}

.toc h4 {
  margin-top: 0;
  color: var(--primary-color);
  font-size: 1.2rem;
}

.toc ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.toc li {
  margin: 12px 0;
  padding-left: 30px;
  position: relative;
  color: var(--text-secondary);
}

.toc .bi {
  position: absolute;
  left: 0;
  top: 4px;
  color: var(--primary-light);
}

/* Lists and Notes */
ul,
ol {
  padding-left: 20px;
  margin-bottom: 1.5rem;
}

li {
  margin-bottom: 0.75rem;
  color: var(--text-secondary);
}

strong {
  color: var(--text-primary);
  font-weight: 600;
}

.note {
  background-color: #eaf4ff;
  border-left: 4px solid var(--primary-light);
  padding: 16px 20px;
  margin: 1.25rem 0;
  border-radius: 6px;
  color: #0f172a;
}

/* Flowchart */
.flowchart {
  background-color: #fbfdff;
  padding: 18px;
  border-radius: 8px;
  font-family: "Consolas", monospace;
  line-height: 1.6;
  overflow-x: auto;
  border: 1px solid rgba(16, 24, 40, 0.04);
  white-space: pre;
}

/* Icons */
.bi {
  margin-right: 8px;
  vertical-align: middle;
}

hr {
  border: 0;
  height: 1px;
  background-color: var(--border-color);
  margin: 40px 0;
}

/* Utility Classes */
.hidden {
  display: none;
}

/* Responsive Adjustments */
@media (max-width: 1024px) {
  .hero-section {
    padding: 48px 0;
  }
  .hero-inner {
    padding: 0 5vw;
  }
  .guide-content {
    padding: 24px 5vw 60px 5vw;
  }
}

@media (max-width: 768px) {
  .hero-section {
    padding: 36px 0;
  }
  .hero-inner {
    padding: 0 4vw;
  }
  .guide-content {
    padding: 20px 4vw 40px 4vw;
  }

  h2 {
    font-size: 1.35rem;
  }
  h3 {
    font-size: 1.15rem;
  }
  h4 {
    font-size: 1.05rem;
  }
  .hero-lang-switch {
    top: 10px;
    right: 10px;
  }
  .hero-lang-switch .lang-btn {
    padding: 10px 14px;
    min-width: 48px;
  }
}

/* Material subtle link style */
a {
  color: var(--primary-dark);
  text-decoration: underline dotted;
}
a:hover {
  color: var(--primary-color);
}
