@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=Playfair+Display:ital,wght@0,400;0,700;1,400&display=swap');

:root {
  --bg-color: #050505;
  --text-primary: #f2f2f2;
  --text-secondary: #a0a0a0;
  --accent-marrow: #e8a87c;
  --accent-kairos: #85b0d6;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
}

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

body {
  font-family: 'Outfit', sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.6;
  overflow-x: hidden;
  background-image: 
    radial-gradient(circle at 15% 50%, rgba(232, 168, 124, 0.04) 0%, transparent 50%),
    radial-gradient(circle at 85% 30%, rgba(133, 176, 214, 0.04) 0%, transparent 50%);
}

h1, h2, h3 {
  font-family: 'Playfair Display', serif;
  font-weight: 700;
}

/* Navbar */
nav {
  position: fixed;
  top: 0;
  width: 100%;
  padding: 1.5rem 5%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: rgba(5, 5, 5, 0.8);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--glass-border);
  transition: all 0.3s ease;
}

.logo {
  font-family: 'Playfair Display', serif;
  font-size: 1.2rem;
  letter-spacing: 2px;
  text-transform: uppercase;
}

.nav-links a {
  color: var(--text-primary);
  text-decoration: none;
  margin-left: 2rem;
  font-size: 0.9rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  transition: color 0.3s ease;
}

.nav-links a:hover {
  color: var(--accent-kairos);
}

/* Hero Section */
.hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 0 5%;
  position: relative;
}

.hero h1 {
  font-size: clamp(3rem, 6vw, 6rem);
  line-height: 1.1;
  margin-bottom: 1rem;
  letter-spacing: 2px;
  background: linear-gradient(to right, #fff, #aaa);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 1s forwards 0.2s;
}

.hero p {
  font-size: 1.2rem;
  color: var(--text-secondary);
  max-width: 600px;
  margin-bottom: 3rem;
  font-weight: 300;
  opacity: 0;
  transform: translateY(30px);
  animation: fadeUp 1s forwards 0.4s;
}

.scroll-indicator {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  animation: bounce 2s infinite;
  opacity: 0.5;
}

/* Books Section */
.books-container {
  padding: 8rem 5%;
  max-width: 1400px;
  margin: 0 auto;
}

.book-showcase {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  margin-bottom: 10rem;
  opacity: 0;
  transform: translateY(50px);
  transition: all 1s ease;
}

.book-showcase.visible {
  opacity: 1;
  transform: translateY(0);
}

.book-showcase:nth-child(even) {
  grid-template-columns: 1fr 1fr;
}

.book-image {
  position: relative;
  border-radius: 4px;
  overflow: hidden;
  box-shadow: 0 30px 60px rgba(0,0,0,0.5);
  transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.book-image.full-jacket img {
  width: 100%;
  height: auto;
  display: block;
}

.book-image::after {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 50%;
  height: 100%;
  background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.1) 50%, rgba(255,255,255,0) 100%);
  transform: skewX(-20deg);
  transition: left 0.7s ease;
}

.book-image:hover {
  transform: translateY(-10px) scale(1.02);
}

.book-image:hover::after {
  left: 150%;
}

.book-info {
  background: var(--glass-bg);
  padding: 3rem;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  backdrop-filter: blur(10px);
}

.book-info h3 {
  font-size: 1.2rem;
  text-transform: uppercase;
  letter-spacing: 2px;
  margin-bottom: 0.5rem;
}

.book-info .title {
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}

.marrow-accent { color: var(--accent-marrow); }
.kairos-accent { color: var(--accent-kairos); }

.book-info p {
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  font-weight: 300;
}

.btn {
  display: inline-block;
  padding: 1rem 2.5rem;
  background: transparent;
  color: var(--text-primary);
  text-decoration: none;
  border: 1px solid var(--glass-border);
  border-radius: 30px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-size: 0.9rem;
  transition: all 0.3s ease;
  cursor: pointer;
  margin-top: 1rem;
}

.btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.3);
}

/* Reviews Section */
.reviews-section {
  padding-top: 5rem;
  border-top: 1px solid var(--glass-border);
  opacity: 0;
  transform: translateY(50px);
  transition: all 1s ease;
}

.reviews-section.visible {
  opacity: 1;
  transform: translateY(0);
}

.section-title {
  text-align: center;
  font-size: 3rem;
  margin-bottom: 4rem;
  letter-spacing: 2px;
}

.review-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  margin-bottom: 2rem;
}

.review-card {
  background: var(--glass-bg);
  padding: 3rem;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  backdrop-filter: blur(10px);
  transition: transform 0.3s ease, background 0.3s ease;
}

.review-card:hover {
  transform: translateY(-5px);
  background: rgba(255, 255, 255, 0.05);
}

.review-card h3 {
  margin-bottom: 1.5rem;
  font-size: 1.3rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.review-card p {
  color: var(--text-secondary);
  font-style: italic;
  font-weight: 300;
  font-size: 1.1rem;
  line-height: 1.8;
}

.featured-review {
  text-align: center;
  margin-top: 2rem;
  padding: 4rem;
  background: linear-gradient(145deg, rgba(255,255,255,0.02), rgba(255,255,255,0.05));
}

.featured-review h3 {
  color: #fff;
}

/* Footer */
footer {
  text-align: center;
  padding: 3rem;
  border-top: 1px solid var(--glass-border);
  color: var(--text-secondary);
  font-size: 0.9rem;
}

/* Animations */
@keyframes fadeUp {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes bounce {
  0%, 20%, 50%, 80%, 100% { transform: translateY(0) translateX(-50%); }
  40% { transform: translateY(-15px) translateX(-50%); }
  60% { transform: translateY(-7px) translateX(-50%); }
}

@media (max-width: 900px) {
  .book-showcase, .book-showcase:nth-child(even) {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  .review-grid {
    grid-template-columns: 1fr;
  }
  .book-image { max-width: 800px; margin: 0 auto; }
}

/* Background Console */
#bg-console {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  z-index: -1;
  pointer-events: none;
  font-family: 'Courier New', Courier, monospace;
  font-size: 1.2rem;
  line-height: 1.8;
  padding: 5%;
  opacity: 0.70;
  overflow: hidden;
  white-space: pre-wrap;
  word-wrap: break-word;
  background: transparent;
  mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 80%);
  -webkit-mask-image: linear-gradient(to bottom, rgba(0,0,0,1) 0%, rgba(0,0,0,0) 80%);
}

.console-user {
  color: #a0a0a0;
}

.console-marrow {
  color: #e8a87c;
  text-shadow: 0 0 5px rgba(232, 168, 124, 0.5);
}

.console-system {
  color: #ff5555;
  font-weight: bold;
}

.console-kairos {
  color: #85b0d6;
  text-shadow: 0 0 5px rgba(133, 176, 214, 0.5);
}

.console-cursor {
  display: inline-block;
  width: 10px;
  height: 1.2rem;
  background-color: var(--text-primary);
  animation: blink 1s step-end infinite;
  vertical-align: middle;
  margin-left: 2px;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

/* Modal Styling */
.modal {
  display: none; 
  position: fixed; 
  z-index: 1000; 
  left: 0;
  top: 0;
  width: 100%; 
  height: 100%; 
  overflow: auto; 
  background-color: rgba(0,0,0,0.8);
  backdrop-filter: blur(5px);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.show {
  display: flex;
  justify-content: center;
  align-items: center;
  opacity: 1;
}

.modal-content {
  background-color: #111;
  border: 1px solid var(--glass-border);
  border-radius: 12px;
  padding: 3rem;
  width: 80%;
  max-width: 700px;
  position: relative;
  box-shadow: 0 15px 30px rgba(0,0,0,0.5);
  font-size: 1.1rem;
}

.close-btn {
  color: var(--text-secondary);
  position: absolute;
  top: 15px;
  right: 25px;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
  transition: color 0.3s ease;
}

.close-btn:hover,
.close-btn:focus {
  color: #fff;
  text-decoration: none;
}

/* Amazon Button */
.amazon-btn {
  background: rgba(255, 153, 0, 0.1);
  border-color: rgba(255, 153, 0, 0.5);
  color: #ff9900;
}

.amazon-btn:hover {
  background: rgba(255, 153, 0, 0.2);
  border-color: #ff9900;
  color: #fff;
}
