/* Gestetner Corporate Theme - Professional Design System v2.0 */

/* ==================== CSS VARIABLES ==================== */
:root {
  /* Colors */
  --primary: #1a4d8f;
  --primary-light: #2563b8;
  --primary-dark: #0f3566;
  --accent: #06b6d4;
  --secondary: #f97316;
  
  /* Text Colors */
  --text: #1e293b;
  --text-light: #475569;
  --text-muted: #64748b;
  
  /* Backgrounds */
  --bg: #ffffff;
  --bg-alt: #f8fafc;
  --bg-dark: #f1f5f9;
  --border: #e2e8f0;
  
  /* Shadows */
  --shadow-sm: 0 1px 2px 0 rgba(0,0,0,0.05);
  --shadow-md: 0 4px 6px -1px rgba(0,0,0,0.1), 0 2px 4px -1px rgba(0,0,0,0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -2px rgba(0,0,0,0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0,0,0,0.1), 0 10px 10px -5px rgba(0,0,0,0.04);
  --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.25);
  
  /* Border Radius */
  --radius-sm: 0.375rem;
  --radius-md: 0.5rem;
  --radius-lg: 0.75rem;
  --radius-xl: 1rem;
  --radius-2xl: 1.5rem;
  --radius-full: 9999px;
  
  /* Spacing */
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-6: 1.5rem;
  --space-8: 2rem;
  --space-12: 3rem;
  --space-16: 4rem;
  --space-20: 5rem;
  --space-24: 6rem;
  
  /* Transitions */
  --transition-fast: 150ms ease;
  --transition-base: 250ms ease;
  --transition-slow: 350ms ease;
}

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

html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
}

/* ==================== TYPOGRAPHY ==================== */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Inter', sans-serif;
  font-weight: 700;
  line-height: 1.2;
  color: var(--text);
  letter-spacing: -0.02em;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 3.75rem);
  margin-bottom: 1.5rem;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  margin-bottom: 1.25rem;
}

h3 {
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin-bottom: 1rem;
}

h4 {
  font-size: clamp(1.25rem, 2.5vw, 1.5rem);
  margin-bottom: 0.75rem;
}

p {
  font-size: 1rem;
  line-height: 1.75;
  color: var(--text-light);
  margin-bottom: 1rem;
}

a {
  transition: all var(--transition-base);
  text-decoration: none;
}

.lead {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--text-light);
  max-width: 65ch;
}

/* ==================== LAYOUT ==================== */
.container {
  width: 100%;
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

.container-narrow {
  max-width: 960px;
}

.container-wide {
  max-width: 1440px;
}

/* ==================== SECTIONS ==================== */
.section {
  padding: 5rem 0;
  position: relative;
}

.section--hero {
  padding: 6rem 0;
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: white;
  position: relative;
  overflow: hidden;
}

.section--hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: 
    radial-gradient(circle at 20% 50%, rgba(255,255,255,0.1) 0%, transparent 50%),
    radial-gradient(circle at 80% 80%, rgba(255,255,255,0.05) 0%, transparent 50%);
  pointer-events: none;
}

.section--alt {
  background: var(--bg-alt);
}

.section--dark {
  background: var(--text);
  color: white;
}

.section__header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 4rem;
}

.section__title {
  position: relative;
  display: inline-block;
}

.section__title::after {
  content: '';
  position: absolute;
  bottom: -12px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--accent));
  border-radius: var(--radius-full);
}

.section__subtitle {
  font-family: 'Inter', sans-serif;
  font-size: 0.875rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--primary);
  margin-bottom: 0.75rem;
}

/* ==================== CARDS ==================== */
.card {
  background: white;
  border-radius: var(--radius-xl);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-base);
  display: flex;
  flex-direction: column;
  height: 100%;
  border: 1px solid var(--border);
}

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

.card__image {
  position: relative;
  overflow: hidden;
  background: var(--bg-dark);
  aspect-ratio: 16 / 10;
}

.card__image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform var(--transition-slow);
}

.card:hover .card__image img {
  transform: scale(1.05);
}

.card__badge {
  position: absolute;
  top: 1rem;
  right: 1rem;
  background: white;
  color: var(--primary);
  padding: 0.5rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  box-shadow: var(--shadow-md);
}

.card__content {
  padding: 2rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.card__title {
  font-size: 1.5rem;
  margin-bottom: 0.75rem;
  color: var(--text);
}

.card__description {
  flex: 1;
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

.card__footer {
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border);
  background: var(--bg-alt);
}

/* ==================== GRIDS ==================== */
.grid {
  display: grid;
  gap: 2rem;
}

.grid--2 {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.grid--4 {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

@media (min-width: 768px) {
  .grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
  
  .grid--4 {
    grid-template-columns: repeat(4, 1fr);
  }
}

/* ==================== BUTTONS ==================== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  font-family: 'Inter', sans-serif;
  font-size: 1rem;
  font-weight: 600;
  text-decoration: none;
  border: none;
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-base);
  white-space: nowrap;
}

.btn--primary {
  background: var(--primary);
  color: white;
  box-shadow: var(--shadow-md);
}

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

.btn--secondary {
  background: white;
  color: var(--primary);
  border: 2px solid var(--primary);
}

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

.btn--large {
  padding: 1.25rem 3rem;
  font-size: 1.125rem;
}

.btn--small {
  padding: 0.5rem 1.5rem;
  font-size: 0.875rem;
}

.btn--icon {
  width: 48px;
  height: 48px;
  padding: 0;
  border-radius: var(--radius-full);
}

/* ==================== HEADER ==================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: white;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-base);
}

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

.header__topbar {
  background: var(--primary-dark);
  color: white;
  padding: 0.75rem 0;
  font-size: 0.875rem;
}

.header__topbar-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header__contact {
  display: flex;
  gap: 1.5rem;
}

.header__contact a {
  color: white;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  opacity: 0.9;
  transition: opacity var(--transition-fast);
}

.header__contact a:hover {
  opacity: 1;
}

.header__social {
  display: flex;
  gap: 1rem;
}

.header__social a {
  color: white;
  opacity: 0.8;
  transition: all var(--transition-fast);
}

.header__social a:hover {
  opacity: 1;
  transform: translateY(-2px);
}

.header__main {
  padding: 1.25rem 0;
}

.header__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header__logo img {
  height: 48px;
  transition: transform var(--transition-fast);
}

.header__logo:hover img {
  transform: scale(1.05);
}

.nav__menu {
  display: flex;
  gap: 0.5rem;
  list-style: none;
  position: relative;
}

.nav__menu > li {
  position: relative;
}

.nav__link {
  color: var(--text);
  text-decoration: none;
  padding: 0.75rem 1.25rem;
  font-weight: 500;
  font-size: 0.9375rem;
  border-radius: var(--radius-md);
  transition: all var(--transition-fast);
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.nav__link::after {
  content: '';
  position: absolute;
  bottom: 8px;
  left: 1.25rem;
  right: 1.25rem;
  height: 2px;
  background: var(--primary);
  transform: scaleX(0);
  transition: transform var(--transition-base);
}

.nav__link:hover,
.nav__link.active {
  color: var(--primary);
  background: var(--bg-alt);
}

.nav__link:hover::after,
.nav__link.active::after {
  transform: scaleX(1);
}

.nav__dropdown-icon {
  font-size: 0.75rem;
  margin-left: 0.25rem;
  transition: transform var(--transition-base);
}

.has-dropdown:hover .nav__dropdown-icon {
  transform: rotate(180deg);
}

/* Dropdown/Submenu Styles */
.nav__submenu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 240px;
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  padding: 0.5rem 0;
  list-style: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-10px);
  transition: all var(--transition-base);
  z-index: 1000;
  border: 1px solid var(--border);
}

.has-dropdown:hover > .nav__submenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.nav__submenu li {
  position: relative;
}

.nav__submenu .nav__link {
  padding: 0.75rem 1.5rem;
  border-radius: 0;
  display: block;
}

.nav__submenu .nav__link::after {
  display: none;
}

.nav__submenu .nav__link:hover {
  background: var(--bg-alt);
  color: var(--primary);
}

/* Nested Submenus (3rd level) */
.nav__submenu .nav__submenu {
  top: 0;
  left: 100%;
  margin-left: 0.5rem;
}

.nav__submenu .has-dropdown:hover > .nav__submenu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text);
  cursor: pointer;
}

.mobile-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  transition: opacity var(--transition-base);
}

.mobile-overlay.active {
  display: block;
  opacity: 1;
}

/* ==================== HERO ==================== */
.hero {
  position: relative;
  min-height: 600px;
  display: flex;
  align-items: center;
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  overflow: hidden;
}

.hero__slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 1s ease-in-out;
  background-size: cover;
  background-position: center;
}

.hero__slide.active {
  opacity: 1;
  position: relative;
}

.hero__overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    rgba(15, 53, 102, 0.95) 0%,
    rgba(26, 77, 143, 0.85) 100%
  );
}

.hero__content {
  position: relative;
  z-index: 10;
  max-width: 700px;
  color: white;
}

.hero__subtitle {
  font-size: 1rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent);
  margin-bottom: 1rem;
}

.hero__title {
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 700;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: white;
}

.hero__description {
  font-size: 1.25rem;
  line-height: 1.6;
  margin-bottom: 2rem;
  color: rgba(255, 255, 255, 0.9);
}

.hero__actions {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.hero__dots {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  gap: 0.75rem;
  z-index: 20;
}

.hero__dot {
  width: 12px;
  height: 12px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.4);
  border: 2px solid white;
  cursor: pointer;
  transition: all var(--transition-base);
}

.hero__dot.active {
  width: 40px;
  background: white;
}

/* ==================== FEATURE BOX ==================== */
.feature-box {
  padding: 2rem;
  background: white;
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border);
  transition: all var(--transition-base);
  text-align: center;
}

.feature-box:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-xl);
  border-color: var(--primary);
}

.feature-box__icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  border-radius: var(--radius-lg);
  color: white;
  font-size: 2rem;
  box-shadow: var(--shadow-lg);
}

.feature-box__title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
}

.feature-box__description {
  color: var(--text-light);
  margin-bottom: 0;
}

/* ==================== CTA SECTION ==================== */
.cta-section {
  background: linear-gradient(135deg, var(--primary-dark), var(--primary));
  color: white;
  padding: 6rem 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.cta-section h2 {
  color: white;
  margin-bottom: 1.5rem;
}

.cta-section p {
  color: rgba(255, 255, 255, 0.9);
  font-size: 1.125rem;
  margin-bottom: 2rem;
}

/* ==================== FOOTER ==================== */
.site-footer {
  background: var(--text);
  color: white;
  padding: 5rem 0 2rem;
}

.footer__widgets {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer__widget h3 {
  color: white;
  font-size: 1.125rem;
  margin-bottom: 1.5rem;
  position: relative;
  padding-bottom: 0.75rem;
}

.footer__widget h3::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 40px;
  height: 3px;
  background: var(--accent);
  border-radius: var(--radius-full);
}

.footer__menu {
  list-style: none;
}

.footer__menu li {
  margin-bottom: 0.75rem;
}

.footer__menu a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  transition: all var(--transition-fast);
  display: inline-block;
}

.footer__menu a:hover {
  color: white;
  padding-left: 0.5rem;
}

.footer__social {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.5rem;
}

.footer__social a {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-full);
  color: white;
  transition: all var(--transition-base);
}

.footer__social a:hover {
  background: var(--primary);
  transform: translateY(-3px);
}

.footer__bottom {
  padding-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.875rem;
}

/* ==================== BREADCRUMBS ==================== */
.breadcrumbs {
  background: var(--bg-alt);
  padding: 1rem 0;
  font-size: 0.875rem;
  border-bottom: 1px solid var(--border);
}

.breadcrumbs a {
  color: var(--primary);
  text-decoration: none;
}

.breadcrumbs a:hover {
  text-decoration: underline;
}

.breadcrumbs span {
  color: var(--text-muted);
  margin: 0 0.5rem;
}

/* ==================== ENTRY CONTENT ==================== */
.entry-content {
  line-height: 1.8;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
  margin-top: 2rem;
  margin-bottom: 1rem;
}

.entry-content ul,
.entry-content ol {
  margin-left: 2rem;
  margin-bottom: 1.5rem;
}

.entry-content li {
  margin-bottom: 0.5rem;
  line-height: 1.7;
}

.entry-content img {
  max-width: 100%;
  height: auto;
  border-radius: var(--radius-lg);
  margin: 1.5rem 0;
}

.entry-content blockquote {
  border-left: 4px solid var(--primary);
  padding-left: 1.5rem;
  margin: 2rem 0;
  font-style: italic;
  color: var(--text-light);
}

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
}

.entry-content th,
.entry-content td {
  padding: 0.75rem;
  border: 1px solid var(--border);
  text-align: left;
}

.entry-content th {
  background: var(--bg-alt);
  font-weight: 600;
}

/* ==================== PAGINATION ==================== */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin: 4rem 0;
  flex-wrap: wrap;
}

.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  border-radius: var(--radius-md);
  background: white;
  color: var(--text);
  text-decoration: none;
  font-weight: 500;
  border: 1px solid var(--border);
  transition: all var(--transition-base);
}

.pagination a:hover {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.pagination .current {
  background: var(--primary);
  color: white;
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
  .section {
    padding: 3rem 0;
  }
  
  .section--hero {
    padding: 4rem 0;
  }
  
  .header__topbar {
    display: none;
  }
  
  .mobile-toggle {
    display: block;
  }
  
  .nav__menu {
    position: fixed;
    top: 0;
    right: -100%;
    width: 280px;
    height: 100vh;
    background: white;
    flex-direction: column;
    padding: 2rem;
    box-shadow: var(--shadow-2xl);
    transition: right var(--transition-base);
    z-index: 1000;
    overflow-y: auto;
    gap: 0;
  }
  
  .nav__menu.active {
    right: 0;
  }
  
  .nav__menu > li {
    width: 100%;
  }
  
  .nav__link {
    display: flex;
    padding: 1rem;
    width: 100%;
    justify-content: space-between;
  }
  
  .nav__link::after {
    display: none;
  }
  
  /* Mobile Dropdown */
  .nav__submenu {
    position: static;
    opacity: 1;
    visibility: visible;
    transform: none;
    box-shadow: none;
    border: none;
    border-left: 2px solid var(--primary);
    margin-left: 1rem;
    padding-left: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height var(--transition-base);
  }
  
  .has-dropdown.open > .nav__submenu {
    max-height: 1000px;
  }
  
  .has-dropdown .nav__dropdown-icon {
    transition: transform var(--transition-base);
  }
  
  .has-dropdown.open .nav__dropdown-icon {
    transform: rotate(180deg);
  }
  
  .grid--2,
  .grid--3,
  .grid--4 {
    grid-template-columns: 1fr;
  }
  
  .hero__actions {
    flex-direction: column;
  }
  
  .hero {
    min-height: 500px;
  }
}

/* ==================== UTILITIES ==================== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.mt-0 { margin-top: 0; }
.mt-4 { margin-top: 1rem; }
.mt-8 { margin-top: 2rem; }
.mt-12 { margin-top: 3rem; }
.mt-16 { margin-top: 4rem; }

.mb-0 { margin-bottom: 0; }
.mb-4 { margin-bottom: 1rem; }
.mb-8 { margin-bottom: 2rem; }
.mb-12 { margin-bottom: 3rem; }
.mb-16 { margin-bottom: 4rem; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}
