* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Source Sans Pro", sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f8f8f8;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  background: transparent;
  backdrop-filter: none;
  z-index: 1000;
  padding: 25px 0;
  transition: all 0.4s ease;
  box-shadow: none;
}

.header.scrolled {
  padding: 15px 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(15px);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.1);
}

.nav-container {
  max-width: 1400px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 40px;

  -webkit-box-flex: 1;
  -ms-flex: 1 1 0px;
  -webkit-flex: 1 1 0px;
  flex: 1 1 0px;
}

.logo {
  font-family: "Playfair Display", serif;
  font-size: 32px;
  font-weight: 400;
  color: #888;
  text-decoration: none;
  letter-spacing: 3px;
  text-transform: uppercase;
  transition: color 0.3s ease;
}

.nav-center {
  display: flex;
  gap: 40px;
  align-items: center;
}

.social-icons {
  display: flex;
  gap: 15px;
  align-items: center;
}

.social-icons a {
  color: #666;
  font-size: 18px;
  transition: all 0.3s ease;
  text-decoration: none;
}

.social-icons a:hover {
  color: #333;
  transform: translateY(-2px);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 20px;
  justify-content: flex-end;
  align-items: center;
}

.nav-menu li {
  position: relative;
}

.nav-menu a {
  color: #888;
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  transition: all 0.3s ease;
  padding: 10px 0;
  position: relative;
}

.nav-menu a:hover {
  color: #fff;
}

.nav-menu a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 1px;
  bottom: 5px;
  left: 0;
  background-color: #777;
  transition: width 0.3s ease;
}

.nav-menu a:hover::after {
  width: 100%;
}


/* Auth Button */
.auth-btn-item {
  display: flex;
  align-items: center;
}

.auth-btn-item a {
  text-decoration: none;
}

.auth-btn {
  background: none;
  border: 1px solid #777;
  color: #777;
  font-size: 18px;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
}

.auth-btn:hover {
  color: #777;
  background: rgba(0, 0, 0, 0.05);
  transform: rotate(15deg);
}

/* Theme Toggle */
.theme-toggle-item {
  display: flex;
  align-items: center;
}


.theme-toggle {
  background: none;
  border: none;
  color: #666;
  font-size: 18px;
  cursor: pointer;
  padding: 8px;
  border-radius: 50%;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
}

.theme-toggle:hover {
  color: #333;
  background: rgba(0, 0, 0, 0.05);
  transform: rotate(15deg);
}

/* Mobile menu toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  color: #333;
  font-size: 20px;
  cursor: pointer;
}

/* Dark Mode Styles */
[data-theme="dark"] {
  background-color: #1a1a1a;
  color: #e0e0e0;
}

[data-theme="dark"] .header {
  background: transparent;
}

[data-theme="dark"] .header.scrolled {
  background: rgba(26, 26, 26, 0.95);
  backdrop-filter: blur(15px);
  box-shadow: 0 2px 20px rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .logo {
  color: #e0e0e0;
}

[data-theme="dark"] .nav-menu a {
  color: #ccc;
}

[data-theme="dark"] .nav-menu a:hover {
  color: #fff;
}

[data-theme="dark"] .nav-menu a::after {
  background-color: #fff;
}

[data-theme="dark"] .social-icons a {
  color: #ccc;
}

[data-theme="dark"] .social-icons a:hover {
  color: #fff;
}

[data-theme="dark"] .theme-toggle {
  color: #ccc;
}

[data-theme="dark"] .theme-toggle:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

[data-theme="dark"] .menu-toggle {
  color: #e0e0e0;
}

/* Hero Section */
.hero {
  height: 100vh;
  background: linear-gradient(135deg, #e8e8e8 0%, #d4d4d4 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: background 0.3s ease;
}

[data-theme="dark"] .hero {
  background: linear-gradient(135deg, #2c2c2c 0%, #1a1a1a 100%);
}

.hero-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  /* background: url("images/bg_movie.jpg") center/cover; */
  background-image:
    linear-gradient(135deg, rgba(16, 14, 25, 0.9), rgba(46, 42, 66, 0.8)),
    url('images/bg_movie.jpg');
  background-size: cover;
  background-position: center;
  z-index: 1;
}

.hero-content {
  z-index: 2;
  position: relative;
  max-width: 800px;
  margin: 0 auto;
}

.hero-portrait2 {
  width: 400px;
  height: 600px;
  background: linear-gradient(135deg, #f0f0f0 0%, #e0e0e0 100%);
  border-radius: 10px;
  margin: 0 auto 40px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

.hero-portrait {
  width: 400px;
  height: 600px;
  background-image: url("images/portrait.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: 10px;
  margin: 0 auto 40px;
  position: relative;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.15);
}

/* Keep the overlay for text readability */
.hero-portrait::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.3) 100%);
}

[data-theme="dark"] .hero-portrait {
  background-image: url("images/portrait.jpg");
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.hero-portrait::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(180deg, transparent 0%, rgba(0, 0, 0, 0.1) 100%);
}

.hero-text {
  position: absolute;
  bottom: 40px;
  left: 50%;
  transform: translateX(-50%);
  text-align: center;
  color: white;
  z-index: 3;
}

.hero h1 {
  font-family: "Playfair Display", serif;
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 300;
  color: #888;
  margin-bottom: 10px;
  letter-spacing: 2px;
  animation: fadeInUp 1s ease-out;
  transition: color 0.3s ease;
}

[data-theme="dark"] .hero h1 {
  color: #e0e0e0;
}

.hero p {
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: #888;
  font-weight: 300;
  letter-spacing: 1px;
  animation: fadeInUp 1s ease-out 0.3s both;
  transition: color 0.3s ease;
}

[data-theme="dark"] .hero p {
  color: #ccc;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Main Sections */
.section {
  padding: 80px 0;
  position: relative;
  transition: background-color 0.3s ease;
}

.section:nth-child(even) {
  background: #fff;
}

.section:nth-child(odd) {
  background: #f8f8f8;
}

[data-theme="dark"] .section:nth-child(even) {
  background: #222;
}

[data-theme="dark"] .section:nth-child(odd) {
  background: #1a1a1a;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

.section-title {
  font-family: "Playfair Display", serif;
  font-size: clamp(2.5rem, 5vw, 3.5rem);
  color: #333;
  text-align: center;
  margin-bottom: 60px;
  font-weight: 300;
  letter-spacing: 1px;
  position: relative;
  transition: color 0.3s ease;
}

[data-theme="dark"] .section-title {
  color: #e0e0e0;
}

.section-title::after {
  content: "";
  position: absolute;
  bottom: -15px;
  left: 50%;
  transform: translateX(-50%);
  width: 60px;
  height: 2px;
  background: #333;
  transition: background 0.3s ease;
}

[data-theme="dark"] .section-title::after {
  background: #e0e0e0;
}

.section-content {
  color: #666;
  font-size: 16px;
  line-height: 1.8;
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
  font-weight: 300;
  transition: color 0.3s ease;
}

[data-theme="dark"] .section-content {
  color: #ccc;
}

/* Bio Section with Image */
.bio-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
  margin-top: 60px;
}

.bio-image {
  width: 100%;
  height: 500px;
  background-image: url("images/kostners.jpeg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border-radius: 10px;
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
  transition: all 0.3s ease;
  object-fit: cover;
}

[data-theme="dark"] .bio-image {
  background-image: url("images/kostners.jpeg");
  box-shadow: 0 15px 40px rgba(0, 0, 0, 0.3);
}

.bio-text {
  text-align: left;
}

.bio-text h3 {
  font-family: "Playfair Display", serif;
  font-size: 28px;
  color: #333;
  margin-bottom: 20px;
  font-weight: 400;
  transition: color 0.3s ease;
}

[data-theme="dark"] .bio-text h3 {
  color: #e0e0e0;
}

.bio-text p {
  color: #666;
  line-height: 1.8;
  margin-bottom: 20px;
  transition: color 0.3s ease;
}

[data-theme="dark"] .bio-text p {
  color: #ccc;
}

/* Grid Layout for sections */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 40px;
  margin-top: 60px;
}

.grid-3-columns {
  display: grid;
  /* Defines the container as a grid */
  grid-template-columns: repeat(3, 1fr);
  /* Creates three equal-width columns */
  gap: 20px;
  /* Adds a gap between grid items */
}

.card {
  background: #fff;
  border-radius: 10px;
  padding: 40px;
  text-align: left;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  border: 1px solid #f0f0f0;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

[data-theme="dark"] .card {
  background: #2a2a2a;
  border: 1px solid #3a3a3a;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

[data-theme="dark"] .card:hover {
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.card h3 {
  font-family: "Playfair Display", serif;
  color: #333;
  font-size: 24px;
  margin-bottom: 20px;
  font-weight: 400;
  transition: color 0.3s ease;
}

[data-theme="dark"] .card h3 {
  color: #e0e0e0;
}

.card p {
  color: #666;
  line-height: 1.7;
  font-weight: 300;
  transition: color 0.3s ease;
}

[data-theme="dark"] .card p {
  color: #ccc;
}

/* Book Section */
.book-showcase {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 60px;
  align-items: center;
  margin-top: 60px;
}

.book-cover {
  width: 300px;
  height: 450px;
  background: linear-gradient(135deg, #2c3e50 0%, #34495e 100%);
  border-radius: 5px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
  position: relative;
  overflow: hidden;
  transition: all 0.3s ease;
}

[data-theme="dark"] .book-cover {
  background: linear-gradient(135deg, #1a2332 0%, #243447 100%);
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.book-cover::after {
  content: "THE EXPLORER";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%) rotate(-90deg);
  color: white;
  font-family: "Playfair Display", serif;
  font-size: 24px;
  font-weight: 600;
  letter-spacing: 3px;
}

.book-info h3 {
  font-family: "Playfair Display", serif;
  font-size: 32px;
  color: #333;
  margin-bottom: 20px;
  font-weight: 400;
  transition: color 0.3s ease;
}

[data-theme="dark"] .book-info h3 {
  color: #e0e0e0;
}

.book-info .subtitle {
  font-style: italic;
  color: #666;
  font-size: 18px;
  margin-bottom: 30px;
  transition: color 0.3s ease;
}

[data-theme="dark"] .book-info .subtitle {
  color: #ccc;
}

.book-info p {
  transition: color 0.3s ease;
}

[data-theme="dark"] .book-info p {
  color: #ccc;
}

/* Footer */
.footer {
  background: #333;
  color: #fff;
  text-align: center;
  padding: 60px 0;
  transition: background-color 0.3s ease;
}

[data-theme="dark"] .footer {
  background: #111;
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 40px;
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 30px;
  margin-bottom: 30px;
}

.footer-social a {
  color: #ccc;
  font-size: 24px;
  transition: all 0.3s ease;
}

.footer-social a:hover {
  color: #fff;
  transform: translateY(-3px);
}

[data-theme="dark"] .footer-social a {
  color: #999;
}

[data-theme="dark"] .footer-social a:hover {
  color: #e0e0e0;
}

.footer p {
  color: #ccc;
  font-size: 14px;
  font-weight: 300;
  transition: color 0.3s ease;
}

[data-theme="dark"] .footer p {
  color: #999;
}

/* Responsive Design */
@media (max-width: 768px) {
  .nav-container {
    padding: 0 20px;
  }

  .nav-center {
    display: none;
  }

  .nav-menu {
    position: fixed;
    top: 0;
    right: -100%;
    height: 100vh;
    width: 80%;
    background: rgba(255, 255, 255, 0.98);
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transition: right 0.3s ease;
    backdrop-filter: blur(15px);
    gap: 30px;
  }

  [data-theme="dark"] .nav-menu {
    background: rgba(26, 26, 26, 0.98);
  }

  .nav-menu.active {
    right: 0;
  }

  .nav-menu li {
    margin: 10px 0;
  }

  .menu-toggle {
    display: block;
    z-index: 1001;
  }

  .container {
    padding: 0 20px;
  }

  .section {
    padding: 60px 0;
  }

  .bio-content {
    grid-template-columns: 1fr;
    gap: 40px;
  }

  .book-showcase {
    grid-template-columns: 1fr;
    gap: 40px;
    text-align: center;
  }

  .book-cover {
    margin: 0 auto;
  }

  .grid {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .grid-3-columns {
    grid-template-columns: 1fr;
    gap: 30px;
  }

  .card {
    padding: 30px;
  }

  .hero-portrait {
    width: 280px;
    height: 420px;
  }

  .footer-content {
    padding: 0 20px;
  }
}

@media (max-width: 480px) {
  .logo {
    font-size: 24px;
    letter-spacing: 2px;
  }

  .hero-portrait {
    width: 240px;
    height: 360px;
  }

  .section-title {
    font-size: 2rem;
  }

  .nav-container {
    padding: 0 15px;
  }
}

/* Scroll Animations */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.8s ease-out;
}

.animate-on-scroll.animated {
  opacity: 1;
  transform: translateY(0);
}