:root{
  --bg:#0b1220;
  --panel:#121a2b;
  --panel-2:#0f1726;
  --card:#0f1726;
  --text:#e7ecf6;
  --muted:#9fb0d0;
  --primary:#2f6df6;
  --danger:#ef4444;
  --border:#24324c;
}

*{box-sizing:border-box}
html,body{height:100%}
html{color-scheme:dark}
body{
  margin:0; font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,Arial,sans-serif;
  background:linear-gradient(180deg,var(--bg),#0e1626 60%,var(--bg));
  color:var(--text);
}
/* ====== NAVBAR (solda brand, sağda butonlar) ====== */
.navbar{
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 12px 16px;
  background: rgba(10,16,30,.85); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--border);
}

/* Sol: ÖGG Portalı / Dilekçeler */
.brand{ display:flex; align-items:center; gap:8px; min-width:0; }
.brand .logo{ color: var(--primary); font-weight: 800; letter-spacing:.2px; }
.brand .divider{ opacity:.55; color: var(--muted); font-weight:700; }
.brand .trail{ color: var(--muted); font-weight:700; }

/* Sağ: Aksiyon butonları (YAN YANA, asla sarma yapma) */
.nav-actions{
  display:flex; align-items:center; gap: clamp(6px, 1.6vw, 12px);
  flex-wrap: nowrap;                       /* <— alta düşmesin */
}
.navbar a{
  display:inline-block;
  padding: clamp(6px, 1.2vw, 10px) clamp(10px, 2vw, 14px);  /* küçülür/büyür */
  border-radius:12px;
  background: transparent;
  color: var(--text);
  text-decoration:none;
  border:1px solid var(--border);
  font-weight:700;
  font-size: clamp(11px, 1.5vw, 15px);     /* yazı da ölçeklensin */
  line-height:1.1;
  white-space: nowrap;                     /* satır kırma yok */
  transition: background .15s, border-color .15s, transform .06s;
}
.navbar a:hover{ background:#131e33; border-color:#3a527a; }
#logoutBtn{ color:#ffb4b4; }
#logoutBtn:hover{ background:#3a0f12; border-color:#5a1a1f; }

/* Çok dar cihazlarda butonları biraz daha sıkıştır */
@media (max-width: 360px){
  .navbar a{ padding: 6px 10px; font-size: 11.5px; }
}



/* ====== CONTAINER ====== */
.container{ max-width:980px; margin:22px auto; padding:0 16px }

/* ====== HEADER ====== */
.page-head{ margin-bottom:12px }
.page-head h1{ margin:0 0 6px; font-size:22px }
.page-head .lead{ margin:0; color:var(--muted) }
.value-chips{
  display:flex; flex-wrap:wrap; gap:8px; margin:10px 0 0; padding:0; list-style:none;
}
.value-chips li{
  background:#19253d; color:#b7c9ff; border:1px solid #2a3b62;
  padding:6px 10px; border-radius:999px; font-size:12px; font-weight:700;
}

/* ====== BANNER / CTA ====== */
.trial-info{
  margin:12px 0; padding:10px 12px; border-radius:12px;
  background:#0e1f1d; color:#b7ffea; border:1px solid #1f3e39;
}
.lock-banner{
  display:flex; align-items:flex-start; gap:16px;
  margin:12px 0 16px; padding:16px; border-radius:16px;
  background:linear-gradient(180deg,#1a1320,#161b2a);
  border:1px solid #3a2d51;
}
.lock-banner h3{ margin:0 0 4px }
.lock-banner p{ margin:0 0 8px; color:#cfc8de }
.lock-banner ul{ margin:0; padding-left:18px; color:#bfb6d4 }
.btn-premium{
  display:inline-block; padding:10px 14px; border-radius:12px;
  background:#ffd166; color:#0f172a; border:1px solid #f4c151;
  font-weight:800; text-decoration:none;
}

/* ====== FORM KART ====== */
.form-card{
  background:linear-gradient(180deg,var(--panel),var(--panel-2));
  border:1px solid var(--border); border-radius:18px; padding:16px;
  box-shadow:0 0 0 1px rgba(255,255,255,.03) inset;
}
label{ display:block; font-weight:700; margin:10px 0 6px }
input, select, textarea{
  width:100%; color:var(--text); background:#0f1726;
  border:1px solid var(--border); border-radius:12px; padding:10px 12px; font-size:15px;
}
input:focus, select:focus, textarea:focus{ outline:none; border-color:#3a527a; box-shadow:0 0 0 3px rgba(47,109,246,.18) }
textarea{ min-height:110px; resize:vertical }

.grid-2{ display:grid; grid-template-columns:1fr 1fr; gap:12px }
@media (max-width:720px){ .grid-2{ grid-template-columns:1fr } }

/* Stepper (görsel rehber) */
.stepper{ display:flex; align-items:center; gap:8px; margin:-2px 0 10px; color:#aab9d6 }
.stepper .dot{
  display:inline-grid; place-items:center; width:26px; height:26px; border-radius:999px;
  border:1px solid #3a527a; background:#0f1726; font-weight:800;
}
.stepper .dot.active{ background:#2f6df6; border-color:#2f6df6; color:#fff }
.stepper .sep{ width:24px; height:1px; background:#2a3b62; opacity:.65 }
.stepper .label{ margin-right:6px; font-size:12px }

/* Önizleme (A4 kağıt görünümü) */
.preview-wrap{ margin-top:12px }
.preview-head{ display:flex; align-items:baseline; gap:10px }
.preview-head .hint{ color:#9fb0d0; font-size:12px }
.paper{
  background:#ffffff; color:#0b1220; border-radius:12px;
  border:1px solid #d4d9e3; box-shadow:0 10px 28px rgba(0,0,0,.25);
  padding:16mm; /* A4 kenarı hissi */
  min-height:297mm; /* görünüm için A4 yüksekliği */
  font-family: "Times New Roman", serif;
}

/* Butonlar */
.buttons{
  display:flex; gap:10px; flex-wrap:wrap; margin-top:14px;
}
.buttons button{
  flex:1 1 30%;
  background:var(--primary); color:#fff; border:1px solid var(--primary);
  border-radius:12px; padding:12px; font-weight:800; cursor:pointer;
}
.buttons button:hover{ filter:brightness(.96) }
.buttons button[disabled]{ opacity:.5; cursor:not-allowed }

/* Mobilde alt yapışkan aksiyon çubuğu */
@media (max-width:720px){
  .buttons{
    position:sticky; bottom:0; z-index:5;
    background:linear-gradient(180deg, rgba(11,18,32,0), #0b1220 40%);
    padding:10px 4px 6px;
  }
  .buttons button{ flex:1 1 100% }
}
/* ---- Mobilde önizleme kompakt olsun ---- */

/* Masaüstünde de çok uzun olmasın: görünüm yüksekliğiyle sınırla */
.paper{
  min-height: auto;                  /* A4 sabit yüksekliği iptal */
  height: clamp(280px, 56vh, 720px); /* ekrana göre ölçeklenir */
  overflow: auto;                    /* içerik taşarsa kaydır */
}

/* Mobil: daha da küçült, okuması rahat kalsın */
@media (max-width: 720px){
  .preview-wrap{                     /* etrafına ince çerçeve + yastık */
    max-height: none;
    padding: 6px;
    border-radius: 14px;
  }
  .paper{
    height: clamp(220px, 46vh, 520px);
    padding: 10mm;                   /* A4 hissi kalsın */
    font-size: 14px;
    line-height: 1.45;
  }
}

/* Çok dar ekranlar */
@media (max-width: 380px){
  .paper{
    height: clamp(200px, 44vh, 460px);
    padding: 8mm;
    font-size: 13px;
  }
}
