/**
 * JeNNa - Telli Defter Tasarım Stilleri (notebook.css)
 * Gerçekçi ahşap masa, 3D metalik spiral halkalar, kağıt dokusu ve sekmeler
 */

:root {
  --desk-bg: #0b1528;
  --desk-gradient: radial-gradient(circle at 50% 20%, #172d54 0%, #0d1c38 60%, #071021 100%);
  --paper-cream: #fdfbf7;
  --paper-line: rgba(180, 165, 145, 0.22);
  --paper-edge-shadow: rgba(45, 30, 15, 0.12);
  --notebook-leather: #3c2a21;
  --notebook-border: #d7cdbe;
  --spiral-metal-light: #f5f5f5;
  --spiral-metal-mid: #9c9a96;
  --spiral-metal-dark: #3a3836;
  --spiral-shadow: rgba(0, 0, 0, 0.45);
  
  --title-navy: #182e4e;
  --title-navy-hover: #234975;
  
  --text-primary: #2b2520;
  --text-secondary: #63574c;
  --text-muted: #8e8072;
  --brand-terracotta: #b85d38;
  --brand-sage: #52796f;
  --brand-blue: #3d6a85;
  --brand-plum: #7a4f6d;
  
  --tab-width: 48px;
  --tab-height: 110px;
  --font-serif: 'Playfair Display', 'Lora', Georgia, serif;
  --font-sans: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
  --font-hand: 'Caveat', cursive, handwriting;
}

/* Genel Sayfa & Masa Zemin (Parliament Laciverti) */
body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
  background: var(--desk-bg) var(--desk-gradient);
  font-family: var(--font-sans);
  color: var(--text-primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  overflow-x: hidden;
  position: relative;
}

/* Masadaki Ambiyans Işığı ve Aksesuarlar */
.desk-atmosphere {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 1;
  background: radial-gradient(ellipse 70% 60% at 50% 15%, rgba(65, 125, 220, 0.12) 0%, transparent 80%);
}

/* Üst Masabaşı Başlığı (İnce, Zarif) */
.desk-topbar {
  width: 100%;
  max-width: 1320px;
  padding: 24px 32px 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
  z-index: 20;
}

.desk-brand {
  display: flex;
  align-items: baseline;
  gap: 14px;
  text-decoration: none;
}

.desk-brand-name {
  font-family: var(--font-serif);
  font-size: 38px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: #f7ede2;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
  line-height: 1;
}

.desk-brand-motto {
  font-family: var(--font-hand);
  font-size: 24px;
  color: #e5d5c5;
  opacity: 0.95;
  line-height: 1;
}

.desk-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.secret-admin-trigger {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #c9baa8;
  padding: 8px 14px;
  border-radius: 20px;
  font-size: 13px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.25s ease;
  backdrop-filter: blur(4px);
}

.secret-admin-trigger:hover {
  background: rgba(255, 255, 255, 0.15);
  color: #ffffff;
  border-color: rgba(255, 255, 255, 0.3);
  transform: translateY(-1px);
}

/* ==========================================================
   ANA DEFTER TAŞIYICI (NOTEBOOK CONTAINER)
   ========================================================== */
.notebook-viewport {
  width: 100%;
  max-width: 1400px;
  padding: 20px 24px 80px;
  display: flex;
  justify-content: center;
  box-sizing: border-box;
  z-index: 10;
}

.notebook-container {
  position: relative;
  transition: all 0.5s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* ----------------------------------------------------------
   1. TEK DEFTER MODU (MODE-SINGLE - KAPAK & İLK GÖRÜNÜM)
   ---------------------------------------------------------- */
.notebook-container.mode-single {
  width: 780px;
  max-width: 95vw;
}

.notebook-container.mode-single .open-notebook-wrapper {
  display: none;
}

.notebook-container.mode-single .single-notebook-wrapper {
  display: flex;
  position: relative;
}

.single-cover-book {
  width: 100%;
  min-height: 740px;
  background: var(--paper-cream);
  border-radius: 8px 24px 24px 8px;
  box-shadow: 
    -10px 15px 40px rgba(0, 0, 0, 0.65),
    12px 20px 35px rgba(0, 0, 0, 0.45),
    inset 0 0 40px rgba(195, 175, 145, 0.18);
  border: 1px solid var(--notebook-border);
  position: relative;
  display: flex;
  overflow: visible;
}

/* Sayfa Kenarı Katmanları (Gerçekçi Defter Kalınlığı) */
.single-cover-book::after {
  content: '';
  position: absolute;
  top: 8px;
  right: -10px;
  bottom: 8px;
  width: 12px;
  background: repeating-linear-gradient(
    to right,
    #e8dfd1,
    #e8dfd1 1px,
    #d8cdbc 2px,
    #f2ebd9 3px
  );
  border-radius: 0 4px 4px 0;
  box-shadow: 4px 0 10px rgba(0, 0, 0, 0.25);
  z-index: 2;
}

/* ----------------------------------------------------------
   2. ÇİFT SAYFALI AÇIK DEFTER MODU (MODE-OPEN)
   ---------------------------------------------------------- */
.notebook-container.mode-open {
  width: 1340px;
  max-width: 96vw;
}

.notebook-container.mode-open .single-notebook-wrapper {
  display: none;
}

.notebook-container.mode-open .open-notebook-wrapper {
  display: flex;
  width: 100%;
  min-height: 820px;
  position: relative;
  background: var(--paper-cream);
  border-radius: 16px;
  box-shadow: 
    0 25px 60px rgba(0, 0, 0, 0.7),
    0 10px 25px rgba(0, 0, 0, 0.35),
    inset 0 0 50px rgba(185, 160, 130, 0.15);
  border: 1px solid var(--notebook-border);
}

/* Çift sayfa altındaki kalınlık katmanları */
.open-notebook-wrapper::before {
  content: '';
  position: absolute;
  top: 10px;
  left: -8px;
  bottom: 10px;
  width: 9px;
  background: repeating-linear-gradient(to left, #e8dfd1, #e8dfd1 1px, #d8cdbc 2px);
  border-radius: 4px 0 0 4px;
}

.open-notebook-wrapper::after {
  content: '';
  position: absolute;
  top: 10px;
  right: -9px;
  bottom: 10px;
  width: 9px;
  background: repeating-linear-gradient(to right, #e8dfd1, #e8dfd1 1px, #d8cdbc 2px);
  border-radius: 0 4px 4px 0;
}

/* Sol ve Sağ Sayfalar */
.open-book-spread {
  display: flex;
  width: 100%;
  min-height: 820px;
  position: relative;
  z-index: 5;
}

.page-half {
  flex: 1;
  padding: 42px 48px 50px;
  box-sizing: border-box;
  overflow-y: auto;
  max-height: 860px;
  position: relative;
}

/* Özel Şık Kaydırma Çubuğu */
.page-half::-webkit-scrollbar {
  width: 6px;
}
.page-half::-webkit-scrollbar-track {
  background: transparent;
}
.page-half::-webkit-scrollbar-thumb {
  background: rgba(180, 160, 140, 0.4);
  border-radius: 4px;
}
.page-half::-webkit-scrollbar-thumb:hover {
  background: rgba(140, 120, 100, 0.6);
}

.page-left {
  border-right: 1px solid rgba(0, 0, 0, 0.05);
  padding-right: 54px;
}

.page-right {
  padding-left: 54px;
}

/* ==========================================================
   3D METALİK SPİRAL MEKANİZMASI (SPIRAL BINDING)
   ========================================================== */
/* Tek Defter Sol Kenar Spirali */
.single-spine-spiral {
  position: absolute;
  left: 32px;
  top: 24px;
  bottom: 24px;
  width: 36px;
  z-index: 20;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  pointer-events: none;
}

/* Çift Defter Orta Spirali */
.center-spine-spiral {
  position: absolute;
  left: 50%;
  top: 24px;
  bottom: 24px;
  width: 44px;
  transform: translateX(-50%);
  z-index: 25;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  pointer-events: none;
}

/* Tek Bir Spiral Halka Ünitesi */
.spiral-coil-loop {
  position: relative;
  width: 100%;
  height: 18px;
  margin: 4px 0;
}

/* Kağıttaki Delikler */
.spiral-coil-loop .hole-left,
.spiral-coil-loop .hole-right {
  position: absolute;
  width: 11px;
  height: 14px;
  background: #25201d;
  border-radius: 4px;
  top: 2px;
  box-shadow: inset 1px 1px 3px rgba(0,0,0,0.8), 0 0 1px rgba(255,255,255,0.4);
}

.spiral-coil-loop .hole-left {
  left: -2px;
}

.spiral-coil-loop .hole-right {
  right: -2px;
}

/* Metal Tel Halkası (3D Işık ve Gölge) */
.spiral-coil-loop .ring-wire {
  position: absolute;
  top: -2px;
  left: 3px;
  right: 3px;
  height: 18px;
  border-radius: 9px;
  background: linear-gradient(
    135deg,
    #666666 0%,
    #d8d8d8 25%,
    #ffffff 50%,
    #999999 75%,
    #444444 100%
  );
  box-shadow: 
    0 4px 7px var(--spiral-shadow),
    inset 0 1px 1px rgba(255, 255, 255, 0.9);
  transform: rotate(-3deg);
}

/* ==========================================================
   KENAR İNDEKS SEKME KULAKÇIKLARI (TABS)
   ========================================================== */
.notebook-tabs-spine {
  position: absolute;
  top: 60px;
  right: -46px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  z-index: 10;
}

.notebook-tab-btn {
  width: 48px;
  height: 98px;
  border: none;
  border-radius: 0 10px 10px 0;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 8px 4px;
  box-sizing: border-box;
  font-family: var(--font-sans);
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: #ffffff;
  box-shadow: 
    4px 4px 10px rgba(0, 0, 0, 0.35),
    inset -1px 0 2px rgba(255, 255, 255, 0.4);
  transition: all 0.25s ease;
  position: relative;
  text-decoration: none;
}

.notebook-tab-btn span.tab-icon {
  font-size: 16px;
  margin-bottom: 4px;
}

.notebook-tab-btn span.tab-label {
  writing-mode: vertical-rl;
  text-orientation: mixed;
  transform: rotate(180deg);
}

.notebook-tab-btn:hover {
  width: 58px;
  box-shadow: 6px 6px 14px rgba(0, 0, 0, 0.45);
}

.notebook-tab-btn.active {
  width: 62px;
  font-weight: 800;
  box-shadow: 8px 6px 18px rgba(0, 0, 0, 0.5);
  border-left: 3px solid #ffffff;
}

/* Sekme Renkleri */
.tab-articles { background: var(--brand-terracotta); }
.tab-categories { background: var(--brand-sage); }
.tab-notes { background: var(--brand-blue); }
.tab-contact { background: var(--brand-plum); }
.tab-cover-return { 
  background: #4a453f; 
  margin-top: 24px;
  height: 85px;
}

/* ==========================================================
   KAPAK SAYFASI DETAYLARI (SINGLE MODE COVER)
   ========================================================== */
.cover-page-inner {
  width: 100%;
  padding: 50px 50px 45px 95px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.cover-header-section {
  border-bottom: 2px dashed rgba(180, 160, 140, 0.4);
  padding-bottom: 28px;
}

.cover-badge-top {
  display: inline-block;
  background: rgba(184, 93, 56, 0.12);
  color: var(--brand-terracotta);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 5px 14px;
  border-radius: 20px;
  margin-bottom: 12px;
  text-transform: none;
}

.cover-main-title {
  font-family: var(--font-serif);
  font-size: 52px;
  line-height: 1.1;
  color: var(--title-navy, #182e4e);
  margin: 0 0 10px 0;
  letter-spacing: -0.5px;
  text-shadow: 0 1px 2px rgba(24, 46, 78, 0.12);
}

.cover-main-subtitle {
  font-family: var(--font-hand);
  font-size: 26px;
  color: var(--text-secondary);
  margin: 0;
}

/* Kapak Ortasındaki Kartlar */
.cover-cards-row {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 24px;
  margin: 32px 0;
}

.cover-featured-card {
  background: #ffffff;
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
  border: 1px solid rgba(0, 0, 0, 0.06);
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  position: relative;
}

.cover-featured-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.cover-post-title {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--title-navy, #182e4e);
  margin: 10px 0 8px 0;
  transition: color 0.2s ease;
}

.cover-featured-card:hover .cover-post-title {
  color: var(--title-navy-hover, #234975);
}

.cover-post-excerpt {
  font-size: 13.5px;
  line-height: 1.6;
  color: var(--text-secondary);
  margin: 0 0 16px 0;
}

.cover-post-meta {
  display: flex;
  gap: 12px;
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}

/* Post-it Not (Kapakta) */
.cover-sticky-note {
  background: #fef08a;
  padding: 20px;
  border-radius: 4px;
  box-shadow: 4px 6px 12px rgba(0,0,0,0.12);
  transform: rotate(2deg);
  position: relative;
  font-family: var(--font-hand);
  font-size: 20px;
  line-height: 1.4;
  color: #422006;
}

.cover-sticky-note::before {
  content: '';
  position: absolute;
  top: -10px;
  left: 45%;
  width: 40px;
  height: 18px;
  background: rgba(255, 255, 255, 0.6);
  box-shadow: 0 1px 3px rgba(0,0,0,0.1);
  transform: rotate(-5deg);
}

/* Kapak Alt Bölümü & Defteri Aç Butonu */
.cover-footer-section {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 20px;
  border-top: 1px solid rgba(180, 160, 140, 0.3);
}

.cover-stats-pill {
  display: flex;
  gap: 20px;
}

.cover-stat-item strong {
  display: block;
  font-size: 20px;
  color: var(--brand-terracotta);
  font-family: var(--font-serif);
}

.cover-stat-item span {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
}

.btn-open-notebook {
  background: var(--brand-terracotta);
  color: #ffffff;
  border: none;
  padding: 14px 28px;
  border-radius: 30px;
  font-size: 15px;
  font-weight: 700;
  font-family: var(--font-sans);
  letter-spacing: 0.5px;
  cursor: pointer;
  box-shadow: 0 4px 15px rgba(184, 93, 56, 0.35);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.25s ease;
}

.btn-open-notebook:hover {
  background: #a34e2c;
  box-shadow: 0 6px 20px rgba(184, 93, 56, 0.5);
  transform: translateY(-2px);
}
