:root {
  /* Color Palette - Primary */
  --primary: #6B8DF2;
  --primary-hover: #5474E0;
  --primary-light: rgba(107, 141, 242, 0.08);

  /* Color Palette - Background & Text */
  --bg: #010101;
  --bg-secondary: #111111;
  --text: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.7);

  /* Color Palette - Glass Effect */
  --glass-bg: rgba(20, 20, 30, 0.18);
  --glass-bg-hover: rgba(20, 20, 30, 0.28);
  --glass-border: rgba(255, 255, 255, 0.1);
  --glass-overlay: rgba(1, 1, 1, 0.85);

  /* Spacing & Layout */
  --blur: 16px;
  --navbar-height: 80px;
  --footer-height: 80px;
  --border-radius: 16px;
  --border-radius-sm: 10px;
  --border-radius-xs: 5px;

  /* Transitions & Animations */
  --transition-fast: 0.2s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.35s ease;

  /* Typography */
  --font-primary: "Poppins", sans-serif;
  --font-display: "Labora", sans-serif;

  /* Shadows */
  --shadow-sm: 0 4px 16px rgba(0, 0, 0, 0.4);
  --shadow-md: 0 6px 20px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 10px 35px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 4px 15px rgba(255, 255, 255, 0.2);
}

/* CSS Reset & Box Sizing */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base Typography & Layout */
html {
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-primary);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

/* Lock scroll only when mobile menu is open */
body.menu-open {
  overflow: hidden;
}

/* Media & Images */
img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Links */
a {
  text-decoration: none;
  color: inherit;
  transition: color var(--transition-base);
}

/* Button Reset */
button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* List Reset */
ul, ol {
  list-style: none;
}

/* Focus Styles for Accessibility */
:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Skip Link */
.skip-link {
  position: absolute;
  top: -100px;
  left: 1rem;
  background: var(--primary);
  color: var(--text);
  padding: 0.6rem 1rem;
  border-radius: var(--border-radius-sm);
  z-index: 2000;
  transition: top var(--transition-fast);
}

.skip-link:focus {
  top: 1rem;
}

/* Font Face - Labora */
@font-face {
  font-family: "Labora";
  src: url("../fonts/Labora-Regular.ttf") format("truetype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Labora";
  src: url("../fonts/Labora-Italic.ttf") format("truetype");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

/* ============================================
   NAVIGATION
   ============================================ */
.navbar {
  position: fixed;
  inset: 0 0 auto 0;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.4rem 5%;
  background: var(--glass-bg);
  backdrop-filter: blur(var(--blur));
  -webkit-backdrop-filter: blur(var(--blur));
  border-bottom: 1px solid var(--glass-border);
  border-radius: 0 0 var(--border-radius) var(--border-radius);
  box-shadow: var(--shadow-lg);
  z-index: 1000;
  transition: background var(--transition-base), box-shadow var(--transition-base);
}

.navbar:hover {
  background: var(--glass-bg-hover);
}

.navbar-logo {
  font: 700 2rem var(--font-display);
  transition: color var(--transition-base), transform var(--transition-base);
}

.navbar-logo:hover,
.navbar-logo:focus-visible {
  color: var(--primary);
  transform: scale(1.05);
}

.navbar-logo-middle {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  object-fit: cover;
  margin: 0 1rem;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition-base), box-shadow var(--transition-base);
}

.navbar-logo-middle:hover {
  transform: scale(1.08);
  box-shadow: 0 8px 24px rgba(138, 137, 137, 0.25);
}

.navbar-nav {
  flex: 2;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.5rem;
  transition: left var(--transition-base);
}

.navbar-nav a {
  position: relative;
  padding: 0.6rem 1rem;
  border-radius: var(--border-radius-sm);
  transition: color var(--transition-base), background var(--transition-base);
}

.navbar-nav a::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 2px;
  background: var(--primary);
  transform: scaleX(0);
  transform-origin: center;
  transition: transform var(--transition-slow);
}

.navbar-nav a:hover,
.navbar-nav a:focus-visible,
.navbar-nav a.active {
  color: var(--primary);
  background: var(--primary-light);
}

.navbar-nav a:hover::after,
.navbar-nav a:focus-visible::after,
.navbar-nav a.active::after {
  transform: scaleX(1);
}

/* Hamburger Menu (Mobile) */
.hamburger {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 30px;
  height: 21px;
  cursor: pointer;
  background: none;
  border: none;
  padding: 0;
  z-index: 1100;
}

.hamburger span {
  height: 3px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
  transition: transform var(--transition-base), opacity var(--transition-base);
  transform-origin: center;
}

.hamburger.active span:nth-child(1) {
  transform: translateY(9px) rotate(45deg);
}

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

.hamburger.active span:nth-child(3) {
  transform: translateY(-9px) rotate(-45deg);
}

/* Mobile Nav Overlay */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  pointer-events: none;
  transition: opacity var(--transition-base);
  z-index: 999;
}

.nav-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

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

  .navbar-nav {
    position: fixed;
    top: var(--navbar-height);
    right: 0;
    width: 80%;
    height: calc(100vh - var(--navbar-height));
    left: 100%;
    background: var(--glass-overlay);
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding: 2rem 0;
    gap: 2rem;
    z-index: 1000;
    backdrop-filter: blur(var(--blur));
    -webkit-backdrop-filter: blur(var(--blur));
    transition: left var(--transition-base);
  }

  .navbar-nav.active {
    left: 20%;
  }

  .navbar-logo-middle {
    display: none;
  }
}

/* ============================================
   HERO SECTION
   ============================================ */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: url("../images/header-bg.jpg") center/cover no-repeat;
  position: relative;
  padding: 0 5%;
  padding-top: 90px;
}

.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(1, 1, 1, 0.2),
    rgba(1, 1, 1, 0.8)
  );
  z-index: 1;
}

/* ============================================
   CONTENT AREA
   ============================================ */
.content {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin: 0 auto;
  text-align: center;
  padding: 2rem 0;
}

.content h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 1.5rem;
  line-height: 1.2;
}

.content h1 span {
  color: var(--primary);
}

.content p {
  margin-bottom: 1.5rem;
  font-weight: 300;
  font-style: italic;
  color: var(--text-muted);
}

/* ============================================
   PAGE SECTIONS (inner pages)
   ============================================ */
.page-section {
  padding: calc(var(--navbar-height) + 2rem) 5% 4rem;
  max-width: 1100px;
  margin: 0 auto;
}

.page-title {
  text-align: center;
  font-size: clamp(2rem, 4vw, 2.5rem);
  margin-bottom: 1rem;
}

.page-subtitle {
  text-align: center;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 2.5rem;
}

.about-description {
  font-size: 1.05rem;
  line-height: 1.8;
  margin-bottom: 1.25rem;
  color: var(--text-muted);
}

.about-description strong {
  color: var(--text);
}

/* Contact info grid */
.contact-grid {
  margin-top: 3rem;
  display: flex;
  justify-content: center;
  gap: 2rem;
  flex-wrap: wrap;
  text-align: center;
}

.contact-grid h3 {
  color: var(--primary);
  margin-bottom: 0.5rem;
}

.contact-grid p {
  color: var(--text-muted);
}

/* Portfolio project */
.portfolio-project {
  max-width: 900px;
  margin: 0 auto 4rem auto;
}

.portfolio-project h2 {
  text-align: center;
  margin-bottom: 1.5rem;
  color: var(--primary);
}

/* ============================================
   CALL TO ACTION
   ============================================ */
.cta {
  display: inline-block;
  padding: 0.8rem 2rem;
  background: var(--text);
  color: var(--bg);
  border-radius: var(--border-radius-xs);
  font-weight: 600;
  font-style: italic;
  box-shadow: var(--shadow-glow);
  transition: transform var(--transition-base), background var(--transition-base), box-shadow var(--transition-base);
  animation: pulse 2s infinite;
}

.cta:hover,
.cta:focus-visible {
  transform: translateY(-3px) scale(1.05);
  background: var(--primary);
  color: var(--text);
  box-shadow: 0 0 25px rgba(107, 141, 242, 0.6), var(--shadow-md);
  animation: none;
}

.cta:active {
  transform: translateY(-1px) scale(1.02);
}

.cta-lg {
  padding: 1rem 2.5rem;
  font-size: 1.1rem;
}

@keyframes pulse {
  0% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
  }
  50% {
    box-shadow: 0 0 20px 5px rgba(255, 255, 255, 0.2);
  }
  100% {
    box-shadow: 0 0 0 0 rgba(255, 255, 255, 0.4);
  }
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  background: var(--bg-secondary);
  color: var(--text-muted);
  text-align: center;
  padding: 1.5rem 1rem;
  font-size: 0.9rem;
  border-top: 1px solid var(--glass-border);
}

.site-footer .designer {
  color: var(--primary);
}

/* ============================================
   PHOTO SLIDESHOW / SLIDER
   ============================================ */
.slideshow-container {
  position: relative;
  max-width: 100%;
  width: 100%;
  margin: 2rem auto;
  overflow: hidden;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-lg);
}

.slide {
  display: none;
  width: 100%;
  height: 70vh;
  max-height: 600px;
  object-fit: cover;
  animation: fade 1.5s ease-in-out;
}

.slide.active {
  display: block;
}

/* Navigation arrows */
.prev, .next {
  cursor: pointer;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  padding: 0.75rem 1rem;
  color: white;
  font-weight: bold;
  font-size: 1.5rem;
  transition: background var(--transition-base);
  background: rgba(0, 0, 0, 0.4);
  user-select: none;
  z-index: 10;
  border: none;
  line-height: 1;
}

.prev {
  left: 0;
  border-radius: 0 3px 3px 0;
}

.next {
  right: 0;
  border-radius: 3px 0 0 3px;
}

.prev:hover, .next:hover,
.prev:focus-visible, .next:focus-visible {
  background: rgba(107, 141, 242, 0.8);
}

/* Dots/indicators */
.dots-container {
  text-align: center;
  margin-top: 1rem;
}

.dot {
  cursor: pointer;
  height: 12px;
  width: 12px;
  margin: 0 5px;
  background-color: rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  display: inline-block;
  border: none;
  padding: 0;
  transition: background-color 0.3s ease, transform 0.3s ease;
}

.dot.active, .dot:hover,
.dot:focus-visible {
  background-color: var(--primary);
  transform: scale(1.2);
}

@keyframes fade {
  from { opacity: 0.4; transform: scale(1.02); }
  to { opacity: 1; transform: scale(1); }
}

/* ============================================
   FALLBACKS & BROWSER SUPPORT
   ============================================ */
@supports not (backdrop-filter: blur(16px)) {
  .navbar {
    background: rgba(1, 1, 1, 0.85);
  }

  .navbar-nav {
    background: var(--bg-secondary);
  }
}

/* ============================================
   ACCESSIBILITY - REDUCED MOTION
   ============================================ */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ============================================
   RESPONSIVE TYPOGRAPHY
   ============================================ */
@media (max-width: 992px) {
  .content h1 {
    font-size: 2.5rem;
  }
}

@media (max-width: 768px) {
  .content h1 {
    font-size: 2.2rem;
  }

  .navbar {
    padding: 1rem 5%;
  }

  .slide {
    height: 50vh;
  }
}

@media (max-width: 480px) {
  .content h1 {
    font-size: 2rem;
  }

  .content p {
    font-size: 0.9rem;
  }

  .cta {
    padding: 0.7rem 1.5rem;
    font-size: 0.9rem;
  }

  .slide {
    height: 40vh;
  }
}

/* ============================================
   PRINT STYLES
   ============================================ */
@media print {
  .navbar,
  .hamburger,
  .nav-overlay,
  .site-footer,
  .prev,
  .next,
  .dots-container {
    display: none !important;
  }

  .hero {
    height: auto;
    min-height: auto;
    background: none !important;
    padding-top: 0;
  }

  .hero::before {
    display: none;
  }

  body {
    background: white;
    color: black;
  }

  .content,
  .about-description,
  .page-subtitle {
    color: black;
  }

  .content h1 span {
    color: black;
  }
}
