/* ========== CSS Variables (Theme) ========== */
:root {
  --color-primary: #0F1B2D;
  --color-primary-light: #1E3A5F;
  --color-primary-mid: #2D4A7A;
  --color-primary-subtle: #EBF0F8;
  --color-accent: #F59E0B;
  --color-accent-light: #FBBF24;
  --color-accent-subtle: #FEF3C7;
  --color-bg: #F8FAFC;
  --color-card: #FFFFFF;
  --color-text: #1E293B;
  --color-text-secondary: #64748B;
  --color-text-muted: #94A3B8;
  --color-border: #E2E8F0;
  --color-sidebar-bg: #FFFFFF;
  --color-sidebar-hover: #F1F5F9;
  --color-success: #10B981;
  --color-danger: #EF4444;

  --font-heading: 'DM Serif Display', Georgia, 'Times New Roman', serif;
  --font-body: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --sidebar-width: 280px;
  --topbar-height: 64px;
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --shadow-card: 0 1px 3px rgba(15, 27, 45, 0.06), 0 1px 2px rgba(15, 27, 45, 0.04);
  --shadow-card-hover: 0 10px 25px rgba(15, 27, 45, 0.08), 0 4px 10px rgba(15, 27, 45, 0.04);
  --shadow-topbar: 0 1px 3px rgba(15, 27, 45, 0.08);
  --transition-fast: 150ms ease;
  --transition-normal: 250ms ease;
  --transition-slow: 400ms ease;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--topbar-height) + 24px);
}

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

a {
  color: var(--color-primary-mid);
  text-decoration: none;
  transition: color var(--transition-fast);
}
a:hover {
  color: var(--color-accent);
}

img {
  max-width: 100%;
  height: auto;
}

/* ========== Scrollbar ========== */
::-webkit-scrollbar {
  width: 8px;
}
::-webkit-scrollbar-track {
  background: var(--color-bg);
}
::-webkit-scrollbar-thumb {
  background: var(--color-text-muted);
  border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-text-secondary);
}

/* ========== Top Navigation ========== */
.topbar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--topbar-height);
  background: var(--color-primary);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
  box-shadow: var(--shadow-topbar);
}

.topbar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-family: var(--font-heading);
  font-size: 18px;
  text-decoration: none;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 60%;
}
.topbar-brand:hover {
  color: var(--color-accent-light);
}
.topbar-brand .brand-icon {
  width: 32px;
  height: 32px;
  background: var(--color-accent);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-primary);
  font-size: 16px;
  flex-shrink: 0;
}
.topbar-brand small {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  color: var(--color-text-muted);
  margin-left: 4px;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

/* Language Switcher */
.lang-switcher {
  position: relative;
}
.lang-switcher-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255,255,255,0.1);
  border: 1px solid rgba(255,255,255,0.15);
  color: #fff;
  padding: 7px 14px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  transition: background var(--transition-fast);
}
.lang-switcher-btn:hover {
  background: rgba(255,255,255,0.2);
}
.lang-switcher-btn i {
  font-size: 12px;
  transition: transform var(--transition-fast);
}
.lang-switcher.active .lang-switcher-btn i {
  transform: rotate(180deg);
}
.lang-dropdown {
  position: absolute;
  top: calc(100% + 6px);
  right: 0;
  min-width: 140px;
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  box-shadow: 0 10px 30px rgba(0,0,0,0.15);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-4px);
  transition: all var(--transition-fast);
  overflow: hidden;
  z-index: 100;
}
.lang-switcher.active .lang-dropdown {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.lang-dropdown button {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 100%;
  padding: 10px 16px;
  border: none;
  background: none;
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 14px;
  cursor: pointer;
  transition: background var(--transition-fast);
  text-align: left;
}
.lang-dropdown button:hover {
  background: var(--color-sidebar-hover);
}
.lang-dropdown button.active-lang {
  color: var(--color-accent);
  font-weight: 600;
  background: var(--color-accent-subtle);
}
.lang-dropdown button .lang-flag {
  font-size: 18px;
}

/* Hamburger (mobile) */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 32px;
  height: 32px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}
.hamburger span {
  display: block;
  width: 100%;
  height: 2px;
  background: #fff;
  border-radius: 2px;
  transition: all var(--transition-fast);
}
.hamburger.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}
.hamburger.active span:nth-child(2) {
  opacity: 0;
}
.hamburger.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

/* ========== Sidebar Overlay (mobile) ========== */
.sidebar-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 899;
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-normal);
}
.sidebar-overlay.visible {
  opacity: 1;
  pointer-events: auto;
}

/* ========== Layout ========== */
.layout-wrapper {
  display: flex;
  padding-top: var(--topbar-height);
  min-height: 100vh;
}

/* ========== Sidebar ========== */
.sidebar {
  width: var(--sidebar-width);
  flex-shrink: 0;
  background: var(--color-sidebar-bg);
  border-right: 1px solid var(--color-border);
  height: calc(100vh - var(--topbar-height));
  position: sticky;
  top: var(--topbar-height);
  overflow-y: auto;
  padding: 24px 0;
  z-index: 900;
  transition: transform var(--transition-normal);
}
.sidebar-inner {
  padding: 0 16px;
}

.sidebar-group {
  margin-bottom: 24px;
}
.sidebar-group:last-child {
  margin-bottom: 0;
}

.sidebar-group-title {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  margin-bottom: 4px;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--color-text-muted);
}
.sidebar-group-title i {
  font-size: 12px;
}

.sidebar-nav {
  list-style: none;
}
.sidebar-nav li {
  margin: 2px 0;
}
.sidebar-nav a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  font-size: 14px;
  font-weight: 500;
  color: var(--color-text-secondary);
  text-decoration: none;
  transition: all var(--transition-fast);
}
.sidebar-nav a:hover {
  background: var(--color-sidebar-hover);
  color: var(--color-text);
}
.sidebar-nav a .nav-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--color-border);
  flex-shrink: 0;
  transition: all var(--transition-fast);
}
.sidebar-nav a.active {
  color: var(--color-primary);
  background: var(--color-primary-subtle);
  font-weight: 600;
}
.sidebar-nav a.active .nav-dot {
  background: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-subtle);
}

/* Sub-navigation */
.sidebar-nav .has-subnav {
  position: relative;
}
.sidebar-nav .parent-link {
  font-weight: 600;
  color: var(--color-text);
}
.sidebar-nav-sub {
  list-style: none;
  margin: 4px 0 4px 20px;
  padding: 0;
  border-left: 2px solid var(--color-border);
}
.sidebar-nav-sub a {
  padding: 7px 12px;
  font-size: 13px;
  font-weight: 400;
}
.sidebar-nav-sub a .nav-dot {
  width: 4px;
  height: 4px;
}
.sidebar-nav-sub a.active {
  font-weight: 600;
  background: transparent;
}
.sidebar-nav-sub a.active .nav-dot {
  width: 6px;
  height: 6px;
  background: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-subtle);
}

/* ========== Main Content ========== */
.main-content {
  flex: 1;
  min-width: 0;
  padding: 48px 56px 80px;
  max-width: calc(100% - var(--sidebar-width));
}

/* ========== Hero Section ========== */
.hero-section {
  text-align: center;
  padding: 40px 0 48px;
  margin-bottom: 48px;
  border-bottom: 1px solid var(--color-border);
  opacity: 0;
  transform: translateY(20px);
  animation: fadeInUp 0.6s ease forwards;
}
.hero-section h1 {
  font-family: var(--font-heading);
  font-size: 36px;
  line-height: 1.2;
  color: var(--color-primary);
  margin-bottom: 12px;
}
.hero-section .hero-subtitle {
  font-size: 16px;
  color: var(--color-text-secondary);
  max-width: 640px;
  margin: 0 auto;
}
.hero-section .hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--color-accent-subtle);
  color: #B45309;
  font-size: 13px;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 20px;
  margin-top: 12px;
}
.hero-section .hero-badge i {
  font-size: 12px;
}

/* ========== Section Cards ========== */
.doc-section {
  margin-bottom: 32px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.doc-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section-card {
  background: var(--color-card);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
  box-shadow: var(--shadow-card);
  transition: box-shadow var(--transition-normal);
}
.section-card:hover {
  box-shadow: var(--shadow-card-hover);
}

.section-card h2,
.section-card h3 {
  font-family: var(--font-heading);
  color: var(--color-primary);
  margin-bottom: 16px;
}
.section-card h2 {
  font-size: 28px;
  line-height: 1.2;
}
.section-card h3 {
  font-size: 22px;
  line-height: 1.3;
}
.section-card h4 {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary-light);
  margin-bottom: 8px;
}

.section-card p {
  font-size: 15px;
  line-height: 1.8;
  color: var(--color-text);
  margin-bottom: 16px;
}
.section-card p:last-child {
  margin-bottom: 0;
}

.section-card .contact-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--color-accent);
  font-weight: 600;
}
.section-card .contact-link:hover {
  color: #D97706;
}

/* Feature grid inside cards */
.feature-block {
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid var(--color-border);
}
.feature-block:first-of-type {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}
.feature-block-title {
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 700;
  color: var(--color-primary-light);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.feature-block-title i {
  color: var(--color-accent);
}

.feature-list {
  list-style: none;
  display: grid;
  grid-template-columns: 1fr;
  gap: 6px;
}
.feature-list li {
  position: relative;
  padding: 8px 12px 8px 32px;
  font-size: 14px;
  line-height: 1.6;
  color: var(--color-text);
  border-radius: var(--radius-sm);
  transition: background var(--transition-fast);
}
.feature-list li:hover {
  background: var(--color-sidebar-hover);
}
.feature-list li::before {
  content: '\f00c';
  font-family: 'Font Awesome 6 Free';
  font-weight: 900;
  position: absolute;
  left: 10px;
  top: 10px;
  font-size: 11px;
  color: var(--color-accent);
}
.feature-list li.more-item::before {
  content: '\f141';
}

/* ========== Details / Thank You sections ========== */
.details-card {
  background: linear-gradient(135deg, var(--color-primary) 0%, var(--color-primary-light) 100%);
  color: #fff;
  border: none;
}
.details-card h2,
.details-card h3,
.details-card h4 {
  color: #fff;
}
.details-card p {
  color: rgba(255,255,255,0.85);
}
.details-card a {
  color: var(--color-accent-light);
}
.details-card a:hover {
  color: #fff;
}
.details-card .feature-block-title {
  color: var(--color-accent-light);
}
.details-card .contact-link {
  color: var(--color-accent-light);
}
.details-card .contact-link:hover {
  color: #fff;
}

.thankyou-section {
  text-align: center;
}
.thankyou-section p {
  font-size: 16px;
}
.thankyou-section .thankyou-icon {
  font-size: 48px;
  color: var(--color-accent);
  margin-bottom: 16px;
}

/* ========== Copyright Footer ========== */
.doc-footer {
  text-align: center;
  padding: 32px 0 8px;
  border-top: 1px solid var(--color-border);
  margin-top: 32px;
  opacity: 0;
  animation: fadeIn 0.6s 0.3s ease forwards;
}
.doc-footer p {
  font-size: 13px;
  color: var(--color-text-muted);
}
.doc-footer a {
  color: var(--color-text-muted);
  font-weight: 500;
}
.doc-footer a:hover {
  color: var(--color-accent);
}

/* ========== Animations ========== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* ========== Responsive ========== */
@media (max-width: 1024px) {
  .main-content {
    padding: 32px 32px 64px;
  }
}

@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .sidebar {
    position: fixed;
    top: var(--topbar-height);
    left: 0;
    bottom: 0;
    transform: translateX(-100%);
    z-index: 900;
  }
  .sidebar.open {
    transform: translateX(0);
  }

  .main-content {
    padding: 24px 20px 48px;
    max-width: 100%;
  }

  .hero-section {
    padding: 24px 0 32px;
    margin-bottom: 32px;
  }
  .hero-section h1 {
    font-size: 26px;
  }
  .hero-section .hero-subtitle {
    font-size: 14px;
  }

  .section-card {
    padding: 24px 20px;
  }
  .section-card h2 {
    font-size: 22px;
  }
  .section-card h3 {
    font-size: 18px;
  }

  .feature-list {
    grid-template-columns: 1fr;
  }

  .topbar-brand {
    font-size: 15px;
    max-width: 50%;
  }

  .lang-switcher-btn span {
    display: none;
  }
}

@media (max-width: 480px) {
  .topbar {
    padding: 0 16px;
  }
  .topbar-brand {
    font-size: 14px;
    max-width: 45%;
  }
  .main-content {
    padding: 16px 16px 40px;
  }
  .section-card {
    padding: 20px 16px;
    border-radius: var(--radius-md);
  }
  .hero-section h1 {
    font-size: 22px;
  }
}

/* ========== Utility ========== */
.section-divider {
  height: 1px;
  background: linear-gradient(to right, transparent, var(--color-border), transparent);
  margin: 0 0 32px;
}

.tag-pill {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 2px 10px;
  border-radius: 12px;
  background: var(--color-primary-subtle);
  color: var(--color-primary-mid);
}
