/* ============================================
   Shifrah Global Study and Tourism - Design System
   Unique palette: Sapphire Navy + Antique Gold + Ocean Teal
   ============================================ */

:root,
[data-theme="light"] {
  --primary: #162b4a;
  --primary-dark: #0e1d33;
  --primary-light: #2a4a7a;
  --primary-rgb: 22, 43, 74;
  --secondary: #0e7c86;
  --secondary-dark: #0a5f67;
  --secondary-rgb: 14, 124, 134;
  --accent: #c9a227;
  --accent-light: #e8c547;
  --accent-rgb: 201, 162, 39;
  --coral: #d4654a;
  --dark: #162b4a;
  --dark-soft: #1f3558;
  --gray-900: #0e1d33;
  --gray-700: #4a5568;
  --gray-500: #6b7a8f;
  --gray-300: #d4cfc4;
  --gray-100: #f0ebe3;
  --gray-50: #f8f6f1;
  --white: #ffffff;
  --success: #1a9e6f;
  --warning: #c9a227;
  --danger: #d4654a;
  --info: #0e7c86;
  --bg-body: #f8f6f1;
  --bg-surface: #ffffff;
  --bg-surface-alt: #f0ebe3;
  --bg-header: rgba(255, 255, 255, 0.95);
  --bg-hero-panel: rgba(255, 255, 255, 0.92);
  --text-heading: #162b4a;
  --text-body: #4a5568;
  --text-muted: #6b7a8f;
  --border-color: #e8e2d8;
  --border-light: #f0ebe3;
  --footer-bg: #162b4a;
  --footer-text: #c8d4e0;
  --gradient-hero: linear-gradient(135deg, #162b4a 0%, #0e7c86 50%, #c9a227 100%);
  --gradient-card: linear-gradient(145deg, #ffffff 0%, #f8f6f1 100%);
  --shadow-sm: 0 1px 2px rgba(22, 43, 74, 0.06);
  --shadow-md: 0 4px 6px -1px rgba(22, 43, 74, 0.08), 0 2px 4px -2px rgba(22, 43, 74, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(22, 43, 74, 0.1), 0 4px 6px -4px rgba(22, 43, 74, 0.08);
  --shadow-xl: 0 20px 25px -5px rgba(22, 43, 74, 0.12), 0 8px 10px -6px rgba(22, 43, 74, 0.08);
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Plus Jakarta Sans', var(--font-sans);
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --header-height: 72px;
  color-scheme: light;
}

[data-theme="dark"] {
  --primary: #5b9fd4;
  --primary-dark: #3d7fb8;
  --primary-light: #7eb8e0;
  --primary-rgb: 91, 159, 212;
  --secondary: #3db8c4;
  --secondary-dark: #2a9aa6;
  --secondary-rgb: 61, 184, 196;
  --accent: #e8c547;
  --accent-light: #f5d96a;
  --accent-rgb: 232, 197, 71;
  --coral: #e88a72;
  --dark: #f0ebe3;
  --dark-soft: #1a2d4a;
  --gray-900: #f0ebe3;
  --gray-700: #b8c4d4;
  --gray-500: #8b9bb0;
  --gray-300: #3d5478;
  --gray-100: #243a5c;
  --gray-50: #1a2d4a;
  --bg-body: #0c1525;
  --bg-surface: #152238;
  --bg-surface-alt: #1a2d4a;
  --bg-header: rgba(12, 21, 37, 0.95);
  --bg-hero-panel: rgba(21, 34, 56, 0.9);
  --text-heading: #f0ebe3;
  --text-body: #b8c4d4;
  --text-muted: #8b9bb0;
  --border-color: #2a3f5c;
  --border-light: #1f3350;
  --footer-bg: #080f1a;
  --footer-text: #8b9bb0;
  --gradient-hero: linear-gradient(135deg, #1a2d4a 0%, #0e5f6a 50%, #a88620 100%);
  --gradient-card: linear-gradient(145deg, #152238 0%, #1a2d4a 100%);
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.35), 0 2px 4px -2px rgba(0, 0, 0, 0.25);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.4), 0 4px 6px -4px rgba(0, 0, 0, 0.3);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.45), 0 8px 10px -6px rgba(0, 0, 0, 0.35);
  color-scheme: dark;
}

[data-theme="dark"] .btn-secondary {
  color: #162b4a;
}

[data-theme="dark"] .btn-secondary:hover {
  color: #162b4a;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-sans);
  color: var(--text-body);
  background: var(--bg-body);
  line-height: 1.6;
  overflow-x: hidden;
  transition: background 0.3s ease, color 0.3s ease;
}

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

a {
  text-decoration: none;
  color: inherit;
  transition: var(--transition);
}

ul, ol {
  list-style: none;
}

button, input, select, textarea {
  font-family: inherit;
  font-size: inherit;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section {
  padding: 5rem 0;
}

.section-header {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 3rem;
}

.section-label {
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  color: var(--text-heading);
  line-height: 1.2;
  margin-bottom: 1rem;
}

.section-subtitle {
  font-size: 1.125rem;
  color: var(--text-muted);
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  font-weight: 600;
  font-size: 0.9375rem;
  border-radius: var(--radius-lg);
  border: 2px solid transparent;
  cursor: pointer;
  transition: var(--transition);
  white-space: nowrap;
}

.btn-primary {
  background: var(--primary);
  color: var(--white);
  border-color: var(--primary);
}

.btn-primary:hover {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-secondary {
  background: var(--accent);
  color: var(--primary-dark);
  border-color: var(--accent);
}

.btn-secondary:hover {
  background: var(--accent-light);
  border-color: var(--accent-light);
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-outline {
  background: transparent;
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.6);
}

.btn-outline:hover {
  background: rgba(255, 255, 255, 0.15);
  border-color: var(--white);
}

.btn-outline-dark {
  background: transparent;
  color: var(--primary);
  border-color: var(--primary);
}

.btn-outline-dark:hover {
  background: var(--primary);
  color: var(--white);
}

.btn-whatsapp {
  background: #25d366;
  color: var(--white);
  border-color: #25d366;
}

.btn-whatsapp:hover {
  background: #1da851;
  border-color: #1da851;
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: var(--bg-header);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.header.scrolled {
  box-shadow: var(--shadow-md);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-height);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.25rem;
  color: var(--text-heading);
}

.logo span {
  font-size: clamp(0.8rem, 2.2vw, 1.15rem);
  line-height: 1.2;
  max-width: 200px;
}

@media (min-width: 768px) {
  .logo span {
    max-width: none;
  }
}

.logo-img {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  object-fit: contain;
  flex-shrink: 0;
  background: var(--bg-surface);
}

.logo-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  flex-shrink: 0;
  background: var(--bg-surface);
}

.logo-icon img,
.logo-icon .logo-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.nav {
  display: none;
}

.nav-list {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.nav-link {
  font-weight: 500;
  color: var(--text-body);
  position: relative;
}

.nav-link:hover,
.nav-link.active {
  color: var(--primary);
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: var(--transition);
}

.nav-link:hover::after,
.nav-link.active::after {
  width: 100%;
}

.nav-dropdown {
  position: relative;
}

.nav-dropdown-toggle {
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: inherit;
  padding: 0;
}

.nav-dropdown-toggle::after {
  display: none;
}

.nav-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 0.75rem);
  left: 50%;
  transform: translateX(-50%);
  min-width: 280px;
  max-width: 360px;
  max-height: 70vh;
  overflow-y: auto;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  padding: 0.75rem;
  z-index: 1001;
}

.nav-dropdown.open .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-group {
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-light);
}

.nav-dropdown-group:last-of-type {
  border-bottom: none;
}

.nav-dropdown-label {
  display: block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--primary);
  padding: 0.25rem 0.75rem 0.5rem;
}

.nav-dropdown-link {
  display: block;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-md);
  font-size: 0.9375rem;
  color: var(--text-body);
  transition: var(--transition);
}

.nav-dropdown-link:hover {
  background: rgba(var(--primary-rgb), 0.08);
  color: var(--primary);
}

.nav-dropdown-footer {
  display: block;
  text-align: center;
  padding: 0.75rem;
  margin-top: 0.25rem;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--primary);
  border-top: 1px solid var(--border-light);
}

.mobile-nav-dropdown-toggle {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  font-family: inherit;
  font-size: inherit;
  cursor: pointer;
}

.mobile-nav-submenu {
  display: none;
  max-height: 240px;
  overflow-y: auto;
  padding-left: 0.5rem;
  margin: 0.25rem 0 0.5rem;
}

.mobile-nav-dropdown.open .mobile-nav-submenu {
  display: block;
}

.mobile-nav-sublink {
  display: block;
  padding: 0.5rem 0;
  font-size: 0.875rem;
  color: var(--text-muted);
  border-bottom: 1px solid var(--border-light);
}

.mobile-nav-sublink:hover {
  color: var(--primary);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.lang-switch {
  display: none;
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  color: var(--text-body);
  cursor: pointer;
  font-size: 0.875rem;
}

.theme-toggle {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  background: var(--bg-surface);
  color: var(--text-heading);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.125rem;
  transition: var(--transition);
  flex-shrink: 0;
}

.theme-toggle:hover {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
  transform: scale(1.05);
}

.mobile-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text-heading);
  transition: var(--transition);
}

.mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -5px);
}

.mobile-nav {
  display: none;
  position: fixed;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: var(--bg-surface);
  padding: 1.5rem;
  box-shadow: var(--shadow-lg);
  z-index: 999;
}

.mobile-nav.active {
  display: block;
}

.mobile-nav-list {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.mobile-nav-link {
  font-weight: 500;
  padding: 0.75rem 0;
  border-bottom: 1px solid var(--border-light);
  display: block;
  color: var(--text-body);
}

/* Hero */
.hero {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  background-image: url('../assets/images/hero-background.png');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
  padding-top: var(--header-height);
  overflow: hidden;
}

.hero-content {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 3rem;
  align-items: center;
}

.hero-text {
  color: var(--text-heading);
  background: var(--bg-hero-panel);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 2rem;
  border-radius: var(--radius-2xl);
  max-width: 680px;
  box-shadow: var(--shadow-xl);
  border: 1px solid var(--border-color);
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: rgba(var(--accent-rgb), 0.15);
  color: var(--accent);
  backdrop-filter: blur(8px);
  padding: 0.5rem 1rem;
  border-radius: 2rem;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
  border: 1px solid rgba(var(--accent-rgb), 0.25);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.25rem, 6vw, 3.75rem);
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 1.25rem;
  color: var(--text-heading);
  text-shadow: none;
}

.hero-subtitle {
  font-size: clamp(1.125rem, 2.5vw, 1.375rem);
  opacity: 1;
  margin-bottom: 2rem;
  max-width: 540px;
  color: var(--text-body);
  text-shadow: none;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.hero-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.hero-stat {
  text-align: left;
}

.hero-stat-value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
}

.hero-stat-label {
  font-size: 0.875rem;
  opacity: 1;
  color: var(--text-muted);
}

.hero-visual {
  display: none;
}

.hero-card {
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: var(--radius-2xl);
  padding: 2rem;
  color: var(--white);
}

.hero-card-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}

.hero-mini-card {
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
}

.hero-mini-card .icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.hero-mini-card h4 {
  font-size: 0.875rem;
  font-weight: 600;
}

/* Cards Grid */
.cards-grid {
  display: grid;
  gap: 1.5rem;
}

.cards-grid-2 { grid-template-columns: repeat(1, 1fr); }
.cards-grid-3 { grid-template-columns: repeat(1, 1fr); }
.cards-grid-4 { grid-template-columns: repeat(2, 1fr); }

.countries-grid {
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
}

.countries-menu {
  max-width: 720px;
  margin: 0 auto;
  padding: 2rem;
}

.countries-menu-select {
  font-size: 1rem;
  padding: 1rem 1.25rem;
}

.country-menu-placeholder {
  text-align: center;
  color: var(--text-muted);
  font-size: 0.9375rem;
  margin-top: 1.5rem;
  padding: 1.5rem;
  border: 2px dashed var(--border-color);
  border-radius: var(--radius-lg);
}

.country-menu-detail {
  margin-top: 1.5rem;
}

.country-menu-detail-inner {
  display: flex;
  gap: 1.5rem;
  align-items: flex-start;
}

.country-menu-flag {
  font-size: 4rem;
  line-height: 1;
  flex-shrink: 0;
}

.country-menu-info h3 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--text-heading);
  margin-bottom: 0.75rem;
}

.country-menu-meta {
  font-size: 0.9375rem;
  color: var(--text-muted);
  margin-bottom: 0.375rem;
}

.country-menu-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

@media (max-width: 640px) {
  .country-menu-detail-inner {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .country-menu-actions {
    justify-content: center;
  }

  .nav-dropdown-menu {
    left: auto;
    right: 0;
    transform: none;
  }
}

/* Country Cards (legacy) */
.country-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  text-align: center;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  transition: var(--transition);
  cursor: pointer;
}

.country-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary-light);
}

.country-flag {
  font-size: 3rem;
  margin-bottom: 0.75rem;
  line-height: 1;
}

.country-name {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.25rem;
}

.country-info {
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* Service Cards */
.service-card {
  background: var(--gradient-card);
  border-radius: var(--radius-xl);
  padding: 2rem;
  border: 1px solid var(--border-light);
  transition: var(--transition);
}

.service-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-light);
}

.service-icon {
  width: 56px;
  height: 56px;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  border-radius: var(--radius-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.25rem;
  color: var(--white);
}

.service-title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.service-desc {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* University Cards */
.university-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  transition: var(--transition);
}

.university-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.university-logo {
  height: 120px;
  background: var(--bg-surface-alt);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.5rem;
  border-bottom: 1px solid var(--border-light);
}

.university-body {
  padding: 1.5rem;
}

.university-name {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.25rem;
}

.university-location {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.university-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  font-size: 0.75rem;
  font-weight: 500;
  padding: 0.25rem 0.625rem;
  border-radius: 2rem;
  background: var(--gray-100);
  color: var(--text-body);
}

.tag-primary {
  background: rgba(var(--primary-rgb), 0.12);
  color: var(--primary);
}

/* Testimonials */
.testimonial-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.testimonial-stars {
  color: var(--accent);
  font-size: 1.125rem;
  margin-bottom: 1rem;
}

.testimonial-text {
  font-size: 1rem;
  color: var(--text-body);
  font-style: italic;
  margin-bottom: 1.5rem;
  line-height: 1.7;
}

.testimonial-author {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.testimonial-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--gradient-hero);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 600;
}

.testimonial-name {
  font-weight: 600;
  color: var(--text-heading);
}

.testimonial-role {
  font-size: 0.875rem;
  color: var(--text-muted);
}

/* Scholarship Cards */
.scholarship-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  border-left: 4px solid var(--accent);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.scholarship-card:hover {
  transform: translateX(4px);
  box-shadow: var(--shadow-lg);
}

.scholarship-amount {
  font-family: var(--font-display);
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--accent);
  margin-bottom: 0.5rem;
}

.scholarship-title {
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.scholarship-meta {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.scholarship-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

/* Program Cards */
.program-card {
  position: relative;
  border-radius: var(--radius-xl);
  overflow: hidden;
  aspect-ratio: 4/3;
  cursor: pointer;
}

.program-card-bg {
  position: absolute;
  inset: 0;
  background: var(--gradient-hero);
  transition: var(--transition);
}

.program-card:nth-child(2) .program-card-bg { background: linear-gradient(135deg, #0e7c86, #0a5f67); }
.program-card:nth-child(3) .program-card-bg { background: linear-gradient(135deg, #c9a227, #a88620); }
.program-card:nth-child(4) .program-card-bg { background: linear-gradient(135deg, #d4654a, #b84f38); }
.program-card:nth-child(5) .program-card-bg { background: linear-gradient(135deg, #2a4a7a, #162b4a); }
.program-card:nth-child(6) .program-card-bg { background: linear-gradient(135deg, #0e7c86, #162b4a); }
.program-card:nth-child(7) .program-card-bg { background: linear-gradient(135deg, #5b3a7a, #3d2560); }
.program-card:nth-child(8) .program-card-bg { background: linear-gradient(135deg, #c9a227, #d4654a); }

.program-card:hover .program-card-bg {
  transform: scale(1.05);
}

.program-card-content {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  color: var(--white);
}

.program-icon {
  font-size: 2rem;
  margin-bottom: auto;
}

.program-name {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 700;
}

/* Tools Section */
.tools-grid {
  display: grid;
  gap: 1.5rem;
}

.tool-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 2rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.tool-card h3 {
  font-family: var(--font-display);
  font-size: 1.125rem;
  color: var(--text-heading);
  margin-bottom: 1rem;
}

.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-weight: 500;
  font-size: 0.875rem;
  color: var(--text-body);
  margin-bottom: 0.375rem;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  background: var(--bg-surface);
  color: var(--text-heading);
  transition: var(--transition);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.15);
}

.form-textarea {
  resize: vertical;
  min-height: 120px;
}

.form-row {
  display: grid;
  gap: 1rem;
}

.form-error {
  color: var(--danger);
  font-size: 0.8125rem;
  margin-top: 0.25rem;
}

.form-hint {
  color: var(--text-muted);
  font-size: 0.8125rem;
  margin-top: 0.25rem;
}

.radio-group,
.checkbox-group {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.radio-label,
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.9375rem;
}

.file-upload {
  border: 2px dashed var(--gray-300);
  border-radius: var(--radius-lg);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.file-upload:hover,
.file-upload.dragover {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.05);
}

.file-upload-icon {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

/* Blog Cards */
.blog-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
}

.blog-image {
  height: 180px;
  background: var(--gradient-hero);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
}

.blog-body {
  padding: 1.5rem;
}

.blog-date {
  font-size: 0.8125rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}

.blog-title {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.blog-excerpt {
  font-size: 0.9375rem;
  color: var(--text-muted);
}

/* Newsletter */
.newsletter {
  background: var(--gradient-hero);
  border-radius: var(--radius-2xl);
  padding: 3rem 2rem;
  text-align: center;
  color: var(--white);
}

.newsletter h2 {
  font-family: var(--font-display);
  font-size: 1.75rem;
  margin-bottom: 0.75rem;
}

.newsletter p {
  opacity: 0.9;
  margin-bottom: 1.5rem;
}

.newsletter-form {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 480px;
  margin: 0 auto;
}

.newsletter-form input {
  padding: 0.875rem 1.25rem;
  border: none;
  border-radius: var(--radius-lg);
  font-size: 1rem;
}

/* Footer */
.footer {
  background: var(--footer-bg);
  color: var(--footer-text);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  margin-bottom: 3rem;
}

.footer-brand .logo {
  color: var(--white);
  margin-bottom: 1rem;
}

.footer-brand p {
  font-size: 0.9375rem;
  line-height: 1.7;
  margin-bottom: 1.5rem;
}

.footer-social {
  display: flex;
  gap: 0.75rem;
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-md);
  background: var(--dark-soft);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.125rem;
  transition: var(--transition);
}

.social-link:hover {
  background: var(--primary);
  transform: translateY(-2px);
}

.footer-title {
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--white);
  margin-bottom: 1.25rem;
  font-size: 1rem;
}

.footer-links li {
  margin-bottom: 0.625rem;
}

.footer-links a {
  font-size: 0.9375rem;
  color: var(--gray-300);
}

.footer-links a:hover {
  color: var(--white);
}

.footer-contact li {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
  font-size: 0.9375rem;
}

.footer-bottom {
  border-top: 1px solid var(--dark-soft);
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: center;
  font-size: 0.875rem;
}

.footer-bottom-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.5rem;
}

.footer-bottom-links a:hover {
  color: var(--white);
}

/* Chat Widget */
.chat-widget {
  position: fixed;
  bottom: 1.5rem;
  right: 1.5rem;
  z-index: 1001;
}

.chat-toggle {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--gradient-hero);
  border: none;
  color: var(--white);
  font-size: 1.5rem;
  cursor: pointer;
  box-shadow: var(--shadow-xl);
  transition: var(--transition);
}

.chat-toggle:hover {
  transform: scale(1.1);
}

.chat-panel {
  display: none;
  position: absolute;
  bottom: 80px;
  right: 0;
  width: 360px;
  max-width: calc(100vw - 2rem);
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-xl);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.chat-panel.active {
  display: flex;
  flex-direction: column;
}

.chat-header {
  background: var(--gradient-hero);
  color: var(--white);
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.chat-header h4 {
  font-size: 1rem;
  font-weight: 600;
}

.chat-close {
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.25rem;
  cursor: pointer;
}

.chat-messages {
  height: 300px;
  overflow-y: auto;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.chat-message {
  max-width: 85%;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-lg);
  font-size: 0.875rem;
  line-height: 1.5;
}

.chat-message.bot {
  background: var(--gray-100);
  color: var(--text-body);
  align-self: flex-start;
  border-bottom-left-radius: 4px;
}

.chat-message.user {
  background: var(--primary);
  color: var(--white);
  align-self: flex-end;
  border-bottom-right-radius: 4px;
}

.chat-input-area {
  display: flex;
  gap: 0.5rem;
  padding: 1rem;
  border-top: 1px solid var(--border-light);
}

.chat-input-area input {
  flex: 1;
  padding: 0.625rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  background: var(--bg-surface-alt);
  color: var(--text-heading);
}

.chat-input-area button {
  padding: 0.625rem 1rem;
  background: var(--primary);
  color: var(--white);
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
}

.chat-quick-replies {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0 1rem 1rem;
}

.quick-reply {
  font-size: 0.75rem;
  padding: 0.375rem 0.75rem;
  background: var(--gray-100);
  border: none;
  border-radius: 2rem;
  cursor: pointer;
  transition: var(--transition);
}

.quick-reply:hover {
  background: var(--primary);
  color: var(--white);
}

/* WhatsApp Float */
.whatsapp-float {
  position: fixed;
  bottom: 1.5rem;
  left: 1.5rem;
  z-index: 1000;
  width: 56px;
  height: 56px;
  background: #25d366;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-size: 1.75rem;
  box-shadow: var(--shadow-xl);
  transition: var(--transition);
}

.whatsapp-float:hover {
  transform: scale(1.1);
  background: #1da851;
}

/* Dashboard & Admin */
.page-header {
  position: relative;
  background-image: url('../assets/images/hero-background.png');
  background-position: center center;
  background-size: cover;
  background-repeat: no-repeat;
  background-attachment: fixed;
  color: var(--text-heading);
  padding: calc(var(--header-height) + 3rem) 0 3rem;
  overflow: hidden;
}

.page-header .container {
  position: relative;
  z-index: 1;
  background: var(--bg-hero-panel);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  padding: 2rem;
  border-radius: var(--radius-xl);
  max-width: 900px;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-color);
}

.page-header h1 {
  font-family: var(--font-display);
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  margin-bottom: 0.5rem;
  text-shadow: none;
  color: var(--text-heading);
}

.page-header p {
  text-shadow: none;
  color: var(--text-body);
}

.dashboard-layout {
  display: grid;
  gap: 2rem;
  padding: 2rem 0 4rem;
}

.sidebar {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.sidebar-nav {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.sidebar-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  border-radius: var(--radius-md);
  font-weight: 500;
  color: var(--text-body);
  transition: var(--transition);
}

.sidebar-link:hover,
.sidebar-link.active {
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
}

.dashboard-main {
  min-width: 0;
}

.stats-grid {
  display: grid;
  gap: 1rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.stat-card-value {
  font-family: var(--font-display);
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-heading);
}

.stat-card-label {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.stat-card.trend-up .stat-card-value { color: var(--success); }
.stat-card.trend-primary .stat-card-value { color: var(--primary); }
.stat-card.trend-warning .stat-card-value { color: var(--warning); }

.data-table-wrapper {
  overflow-x: auto;
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
}

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}

.data-table th,
.data-table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
}

.data-table th {
  background: var(--bg-surface-alt);
  font-weight: 600;
  color: var(--text-heading);
  white-space: nowrap;
}

.data-table tr:hover {
  background: var(--bg-surface-alt);
}

.status-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 2rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.status-new { background: rgba(59, 130, 246, 0.1); color: var(--info); }
.status-reviewing { background: rgba(245, 158, 11, 0.1); color: var(--warning); }
.status-applied { background: rgba(139, 92, 246, 0.1); color: #7c3aed; }
.status-approved { background: rgba(16, 185, 129, 0.1); color: var(--success); }
.status-visa { background: rgba(13, 148, 136, 0.1); color: var(--secondary); }

.progress-tracker {
  display: flex;
  justify-content: space-between;
  position: relative;
  margin: 2rem 0;
}

.progress-tracker::before {
  content: '';
  position: absolute;
  top: 20px;
  left: 10%;
  right: 10%;
  height: 3px;
  background: var(--gray-200, #e5e7eb);
}

.progress-step {
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
  z-index: 1;
  flex: 1;
}

.progress-dot {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--gray-200, #e5e7eb);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
  transition: var(--transition);
}

.progress-step.completed .progress-dot,
.progress-step.active .progress-dot {
  background: var(--primary);
  color: var(--white);
}

.progress-label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--gray-500);
  text-align: center;
}

.progress-step.completed .progress-label,
.progress-step.active .progress-label {
  color: var(--primary);
}

.panel {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  margin-bottom: 1.5rem;
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.panel-title {
  font-family: var(--font-display);
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-heading);
}

.panel-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

/* Modal */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-overlay.active {
  display: flex;
}

.modal {
  background: var(--bg-surface);
  border-radius: var(--radius-xl);
  max-width: 600px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  padding: 2rem;
  color: var(--text-body);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--text-heading);
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--gray-500);
}

/* Toast */
.toast-container {
  position: fixed;
  top: calc(var(--header-height) + 1rem);
  right: 1rem;
  z-index: 3000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.toast {
  padding: 1rem 1.25rem;
  border-radius: var(--radius-lg);
  color: var(--white);
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: var(--shadow-lg);
  animation: slideIn 0.3s ease;
}

.toast-success { background: var(--success); }
.toast-error { background: var(--danger); }
.toast-info { background: var(--info); }

@keyframes slideIn {
  from { transform: translateX(100%); opacity: 0; }
  to { transform: translateX(0); opacity: 1; }
}

/* Login */
.auth-container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-surface-alt);
  padding: 2rem 1rem;
}

.auth-card {
  background: var(--bg-surface);
  border-radius: var(--radius-2xl);
  padding: 2.5rem;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 420px;
  border: 1px solid var(--border-light);
}

.auth-card h1 {
  font-family: var(--font-display);
  font-size: 1.5rem;
  text-align: center;
  margin-bottom: 0.5rem;
  color: var(--text-heading);
}

.auth-card .subtitle {
  text-align: center;
  color: var(--text-muted);
  margin-bottom: 2rem;
  font-size: 0.9375rem;
}

/* Appointment */
.time-slots {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
}

.time-slot {
  padding: 0.625rem;
  border: 1px solid var(--gray-300);
  border-radius: var(--radius-md);
  text-align: center;
  font-size: 0.875rem;
  cursor: pointer;
  transition: var(--transition);
}

.time-slot:hover,
.time-slot.selected {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
}

.time-slot.disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

/* Map */
.map-container {
  border-radius: var(--radius-xl);
  overflow: hidden;
  height: 300px;
  background: var(--gray-100);
}

.map-placeholder {
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--gray-500);
  gap: 0.5rem;
}

/* Utility */
.bg-gray { background: var(--bg-surface-alt); }
.text-center { text-align: center; }
.hidden { display: none !important; }
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

/* Responsive */
@media (max-width: 767px) {
  .hero,
  .page-header {
    background-attachment: scroll;
  }
}

/* Form Type Selector */
.form-type-grid {
  display: grid;
  gap: 1.5rem;
  grid-template-columns: 1fr;
}

.form-type-card {
  background: var(--bg-surface);
  border: 2px solid var(--border-color);
  border-radius: var(--radius-2xl);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
}

.form-type-card:hover {
  border-color: var(--primary);
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.form-type-card.selected {
  border-color: var(--primary);
  background: rgba(var(--primary-rgb), 0.05);
  box-shadow: var(--shadow-md);
}

.form-type-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

.form-type-card h3 {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text-heading);
  margin-bottom: 0.5rem;
}

.form-type-card p {
  font-size: 0.9375rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.form-back-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 1rem;
}

.form-type-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(var(--primary-rgb), 0.1);
  color: var(--primary);
  border-radius: 2rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.form-type-badge.tourism {
  background: rgba(var(--secondary-rgb), 0.12);
  color: var(--secondary);
}

.form-section-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--text-heading);
  margin: 0 0 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--primary);
}

.form-section-title:not(:first-of-type) {
  margin-top: 2rem;
}

@media (min-width: 640px) {
  .form-type-grid { grid-template-columns: repeat(2, 1fr); }
  .cards-grid-4 { grid-template-columns: repeat(4, 1fr); }
  .newsletter-form { flex-direction: row; }
  .newsletter-form input { flex: 1; }
  .form-row-2 { grid-template-columns: repeat(2, 1fr); }
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .time-slots { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 768px) {
  .nav { display: block; }
  .mobile-toggle { display: none; }
  .lang-switch { display: block; }
  .cards-grid-2 { grid-template-columns: repeat(2, 1fr); }
  .cards-grid-3 { grid-template-columns: repeat(2, 1fr); }
  .hero-content { grid-template-columns: 1fr 1fr; }
  .hero-visual { display: block; }
  .footer-grid { grid-template-columns: 2fr 1fr 1fr 1fr; }
  .footer-bottom { flex-direction: row; justify-content: space-between; text-align: left; }
  .tools-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-layout { grid-template-columns: 240px 1fr; }
}

@media (min-width: 1024px) {
  .cards-grid-3 { grid-template-columns: repeat(3, 1fr); }
  .cards-grid-4 { grid-template-columns: repeat(4, 1fr); }
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
  .form-row-3 { grid-template-columns: repeat(3, 1fr); }
  #programsGrid { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 1280px) {
  #programsGrid { grid-template-columns: repeat(5, 1fr); }
}

@media (min-width: 1280px) {
  .container { padding: 0 2rem; }
}
