/* ============================================
   GÜNLÜK PRATİK — style.css
   Tüm siteye ait global stil dosyası
   ============================================ */

/* ── 1. Kök Değişkenler ─────────────────── */
:root {
  --primary:      #6c5ce7;
  --primary-dark: #5a4bd1;
  --secondary:    #a29bfe;
  --accent:       #fd79a8;
  --accent-dark:  #e84393;
  --bg:           #f9f9fb;
  --surface:      #ffffff;
  --text:         #2d3436;
  --text-muted:   #636e72;
  --border:       #e0e0ef;

  --success:      #00b894;
  --success-bg:   #e6f9f5;
  --error:        #d63031;
  --error-bg:     #ffeaea;
  --warning:      #e17055;
  --warning-bg:   #fff3ee;
  --info:         #0984e3;
  --info-bg:      #e8f4fd;

  --radius-sm:    8px;
  --radius:       16px;
  --radius-lg:    25px;
  --radius-xl:    40px;

  --shadow-sm:    0 2px 8px rgba(108, 92, 231, 0.08);
  --shadow:       0 10px 30px rgba(108, 92, 231, 0.1);
  --shadow-lg:    0 15px 40px rgba(108, 92, 231, 0.15);

  --font:         'Poppins', sans-serif;
  --transition:   all 0.25s ease;
}

/* ── 2. Reset & Temel ───────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: var(--font);
  background-color: var(--bg);
  color: var(--text);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; transition: var(--transition); }
a:hover { color: var(--primary-dark); }

img { max-width: 100%; display: block; }

/* ── 3. Tipografi ────────────────────────── */
h1 { font-size: clamp(1.8rem, 4vw, 3rem); font-weight: 700; line-height: 1.2; letter-spacing: -0.5px; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem);  font-weight: 600; line-height: 1.3; margin-bottom: 0.5em; }
h3 { font-size: 1.2rem; font-weight: 600; margin-bottom: 0.4em; }
h4 { font-size: 1rem;   font-weight: 600; }
p  { margin-bottom: 1em; color: var(--text-muted); }
p:last-child { margin-bottom: 0; }

/* ── 4. Navbar ───────────────────────────── */
.navbar {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  padding: 0 20px;
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.navbar__logo {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.navbar__logo span { font-weight: 300; color: var(--text-muted); }

.navbar__links {
  display: flex;
  gap: 6px;
  list-style: none;
}
.navbar__links a {
  padding: 7px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.88rem;
  font-weight: 500;
  color: var(--text-muted);
}
.navbar__links a:hover,
.navbar__links a.active {
  background: #f0eeff;
  color: var(--primary);
}

/* Hamburger (mobil) */
.navbar__hamburger {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: 6px;
  background: none;
  border: none;
}
.navbar__hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: var(--transition);
}

/* Açık menü */
.navbar__links.open {
  display: flex;
  flex-direction: column;
  position: absolute;
  top: 62px;
  left: 0;
  right: 0;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 12px 20px 16px;
  gap: 4px;
  box-shadow: var(--shadow);
}

/* ── 5. Breadcrumb ───────────────────────── */
.breadcrumb {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  padding: 7px 0;
  font-size: 0.78rem;
  color: var(--text-muted);
}
.breadcrumb a { color: var(--text-muted); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb__sep { color: var(--border); }
.breadcrumb__current { color: var(--primary); font-weight: 500; }

/* ── 6. Hero / Header ────────────────────── */
.hero {
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  padding: 70px 20px;
  text-align: center;
  border-bottom-left-radius: 60px;
  border-bottom-right-radius: 60px;
  box-shadow: 0 15px 35px rgba(108, 92, 231, 0.2);
}
.hero h1 { color: white; }
.hero p  { color: rgba(255,255,255,0.88); font-weight: 300; font-size: 1.1rem; max-width: 680px; margin: 14px auto 0; }

/* ── 7. Container ────────────────────────── */
.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* ── 8. Kartlar ──────────────────────────── */
.grid-box {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  margin-top: 20px;
}

.card {
  background: var(--surface);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow);
  border: 1px solid transparent;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 180px;
  width: 300px;
  transition: var(--transition);
}
.card:hover {
  transform: translateY(-8px);
  border-color: var(--secondary);
  box-shadow: var(--shadow-lg);
  color: inherit;
}
.card h3 { color: var(--primary); font-size: 1.2rem; margin-bottom: 6px; }
.card p   { font-size: 0.88rem; margin-bottom: 18px; }

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.go-btn { color: var(--accent); font-weight: 700; font-size: 0.9rem; }

/* ── 9. Badge / Seviye Etiketi ───────────── */
.badge {
  display: inline-block;
  padding: 4px 12px;
  border-radius: 30px;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.3px;
  margin-bottom: 10px;
}
.badge--default  { background: #f0eeff; color: var(--primary); }
.badge--A1       { background: #e8f5e9; color: #2e7d32; }
.badge--A2       { background: #e3f2fd; color: #1565c0; }
.badge--B1       { background: #fff8e1; color: #f57f17; }
.badge--B2       { background: #fce4ec; color: #c62828; }
.badge--label    { background: #f0eeff; color: var(--primary); } /* genel etiket */

/* eski .level-tag uyumluluğu */
.level-tag { display: inline-block; background: #f0eeff; color: var(--primary); padding: 5px 12px; border-radius: 15px; font-size: 0.75rem; font-weight: 600; letter-spacing: 0.3px; }

/* ── 10. Tablolar ────────────────────────── */
.table-wrapper { overflow-x: auto; -webkit-overflow-scrolling: touch; border-radius: var(--radius); }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
  background: var(--surface);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}
thead th {
  background: var(--primary);
  color: white;
  font-weight: 600;
  padding: 12px 16px;
  text-align: left;
}
tbody tr:nth-child(even) { background: #fafafa; }
tbody tr:hover { background: #f0eeff; }
tbody td { padding: 10px 16px; border-bottom: 1px solid var(--border); color: var(--text); }
tbody tr:last-child td { border-bottom: none; }

/* ── 11. Örnek Cümle Kutuları ────────────── */
.example-box {
  border-left: 4px solid;
  padding: 14px 18px;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  margin-bottom: 12px;
  font-size: 0.93rem;
}
.example-box--positive  { border-color: var(--success); background: var(--success-bg); }
.example-box--negative  { border-color: var(--error);   background: var(--error-bg); }
.example-box--question  { border-color: var(--primary);  background: #f0eeff; }

.example-box .en { font-weight: 600; color: var(--text); }
.example-box .tr { color: var(--text-muted); font-size: 0.87rem; margin-top: 3px; }

/* ── 12. Bilgi Kutuları ──────────────────── */
.info-box {
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 16px;
  display: flex;
  gap: 12px;
  align-items: flex-start;
  font-size: 0.9rem;
}
.info-box__icon { font-size: 1.2rem; flex-shrink: 0; margin-top: 1px; }
.info-box--tip      { background: var(--success-bg); border-left: 4px solid var(--success); }
.info-box--warning  { background: var(--warning-bg); border-left: 4px solid var(--warning); }
.info-box--summary  { background: var(--info-bg);    border-left: 4px solid var(--info); }
.info-box--compare  { background: #fdf0ff;            border-left: 4px solid #a855f7; }

/* ── 13. Vurgu Renkleri ──────────────────── */
.hl-verb    { color: #0984e3; font-weight: 600; }
.hl-tense   { color: var(--primary); font-weight: 600; }
.hl-neg     { color: var(--error); font-weight: 600; }
.hl-keyword { background: #fff3cd; padding: 1px 5px; border-radius: 4px; font-weight: 600; }

/* ── 14. Alıştırma Inputları ─────────────── */
.exercise-input {
  padding: 9px 14px;
  border: 2px solid var(--border);
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.2s;
  background: var(--surface);
  width: 100%;
}
.exercise-input:focus  { border-color: var(--secondary); }
.exercise-input.correct { border-color: var(--success); background: var(--success-bg); }
.exercise-input.wrong   { border-color: var(--error);   background: var(--error-bg); }

/* ── 15. Quiz Butonları & Skor ───────────── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-family: var(--font);
  font-size: 0.92rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
}
.btn--primary { background: var(--primary); color: white; }
.btn--primary:hover { background: var(--primary-dark); transform: translateY(-2px); box-shadow: var(--shadow); }
.btn--outline { background: transparent; color: var(--primary); border: 2px solid var(--primary); }
.btn--outline:hover { background: #f0eeff; }
.btn--accent  { background: var(--accent); color: white; }
.btn--accent:hover { background: var(--accent-dark); }

.score-box {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--surface);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 22px;
  font-size: 1rem;
}
.score-box__number { font-size: 1.8rem; font-weight: 700; color: var(--primary); line-height: 1; }
.score-box__label  { color: var(--text-muted); font-size: 0.82rem; }

/* ── 16. Progress Bar ────────────────────── */
.progress-wrap {
  background: var(--border);
  border-radius: 30px;
  height: 10px;
  overflow: hidden;
}
.progress-bar {
  height: 100%;
  border-radius: 30px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  transition: width 0.5s ease;
}

/* ── 17. Tooltip ─────────────────────────── */
[data-tooltip] { position: relative; cursor: help; }
[data-tooltip]::after {
  content: attr(data-tooltip);
  position: absolute;
  bottom: calc(100% + 8px);
  left: 50%;
  transform: translateX(-50%);
  background: var(--text);
  color: white;
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 0.78rem;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
  z-index: 100;
}
[data-tooltip]:hover::after { opacity: 1; }

/* ── 18. Footer ──────────────────────────── */
footer {
  text-align: center;
  padding: 48px 20px;
  color: #b2bec3;
  font-size: 0.83rem;
  border-top: 1px solid var(--border);
  margin-top: 60px;
}
footer a { color: #b2bec3; }
footer a:hover { color: var(--primary); }

/* ── 19. Responsive ──────────────────────── */
@media (max-width: 768px) {
  .navbar__links { display: none; }
  .navbar__hamburger { display: flex; }

  .hero { padding: 50px 20px; border-bottom-left-radius: 36px; border-bottom-right-radius: 36px; }
  .hero h1 { font-size: 1.9rem; }

  .card { width: 100%; max-width: 420px; }

  .grid-box { gap: 16px; }

  table { font-size: 0.83rem; }
  thead th, tbody td { padding: 9px 12px; }
}

@media (max-width: 480px) {
  h1 { font-size: 1.6rem; }
  h2 { font-size: 1.3rem; }
  .btn { width: 100%; justify-content: center; }
}

/* ══════════════════════════════════════════════
   20. SIDEBAR LAYOUT
   ══════════════════════════════════════════════ */

/* Sayfa yapısı - Ana içerik + Sidebar */
.page-wrapper {
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
  position: relative;
}

/* Ana içerik - Sidebar için sağda boşluk */
.main-content {
  margin-right: 330px; /* 300px sidebar + 30px gap */
}

/* Sidebar - Absolute positioning ile sağda */
.sidebar-container {
  position: absolute;
  right: 175px;
  top: 0;
  width: 300px;
}

/* Sidebar kutusu */
.sidebar {
  position: sticky;
  top: 20px;
  background: var(--surface);
  border-radius: var(--radius);
  padding: 24px 20px;
  box-shadow: var(--shadow);
  border: 1px solid var(--border);
}

/* Sidebar başlık */
.sidebar__title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary);
  margin: 0 0 18px 0;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--secondary);
}

/* Sidebar liste */
.sidebar__list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.sidebar__item {
  margin-bottom: 8px;
}

/* Sidebar linkler */
.sidebar__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  text-decoration: none;
  color: var(--text);
  font-size: 0.9rem;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.sidebar__link:hover {
  background: var(--bg);
  border-color: var(--secondary);
  transform: translateX(4px);
  color: var(--primary);
}

.sidebar__icon {
  font-size: 1.2rem;
  flex-shrink: 0;
}

.sidebar__text {
  line-height: 1.4;
}

/* ── Responsive: Sidebar mobilde alta kayar ───── */
@media (max-width: 1200px) {
  .sidebar-container {
    position: static;
    width: 100%;
    margin-top: 40px;
  }
  .main-content {
    margin-right: 0;
  }
}

@media (max-width: 768px) {
  .sidebar {
    position: static;
  }
}
