/* mailas — stylesheet
 *
 * Two design standards from the catalogue this project builds against:
 *
 *   46 macOS Masaüstü  (Jony Ive / Apple HIG) — the desktop layout:
 *      three panes, unified toolbar, translucent sidebar, 12px radius,
 *      one soft shadow, rgba(0,0,0,.08) hairlines. Its "avoid" list is
 *      binding: no sharp corners, no heavy shadows, no colour clutter.
 *
 *   54 iOS İnsan Arayüzü (Apple HIG) — the phone layout: 32px bold Large
 *      Title, inset-grouped cards 16px from the edge, translucent
 *      bottom tab bar. Its "avoid" list too: no FAB, no sharp corners,
 *      no brand-coloured surfaces.
 *
 * The two palettes turned out to be the same colour: #007aff is Apple's
 * system blue in light mode and #0a84ff is the same blue in dark mode, so
 * one accent token covers both standards rather than two fighting ones.
 *
 * Behaviour patterns blended in, per the catalogue's own instruction that
 * 34–45 are patterns rather than styles: 34 thumb zone (the primary
 * action is bottom-centre on a phone and never in a top corner, nothing
 * tappable under 44px), 31 accessibility-first (visible focus, nothing
 * carried by colour alone, motion honoured as a preference).
 */

/* ── Tokens ─────────────────────────────────────────────────────────── */

:root {
  color-scheme: light dark;

  --zemin: #e8eaf0;
  --pencere: #f5f5f7;
  --kart: #ffffff;
  --kenar-zemin: rgba(245, 245, 247, 0.72);
  --sekme-zemin: rgba(249, 249, 251, 0.82);

  --metin: #1d1d1f;
  --metin-ikincil: rgba(60, 60, 67, 0.6);
  --metin-ucuncul: rgba(60, 60, 67, 0.3);

  --ayirac: rgba(0, 0, 0, 0.08);
  --vurgu-zemin: rgba(0, 122, 255, 0.1);

  --accent: #007aff;
  --yesil: #34c759;
  --kirmizi: #ff3b30;
  --turuncu: #ff9f0a;

  /* 46: one large soft shadow, never a stack of hard ones. */
  --golge: 0 10px 40px rgba(0, 0, 0, 0.12);

  --r-pencere: 12px;
  --r-kart: 10px;
  --r-alan: 8px;

  --ui: 13px;          /* 46: dense desktop UI text */
  --satir: 14.5px;     /* 54: phone list rows */

  --gecis: 160ms;

  --yazi: -apple-system, BlinkMacSystemFont, "Segoe UI", system-ui,
    "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* A phone's home indicator sits over the tab bar without this. */
  --alt-guvenli: env(safe-area-inset-bottom, 0px);
}

/* Dark tokens are defined three times on purpose: the bare media query
 * for viewers on the system default, guarded so an explicit light choice
 * still wins, and again for an explicit dark choice. Components below
 * only ever read tokens, never a literal, so all three paths resolve. */
@media (prefers-color-scheme: dark) {
  :root:not([data-tema="light"]) {
    --zemin: #000000;
    --pencere: #1c1c1e;
    --kart: #1c1c1e;
    --kenar-zemin: rgba(28, 28, 30, 0.72);
    --sekme-zemin: rgba(22, 22, 24, 0.86);
    --metin: #f5f5f7;
    --metin-ikincil: rgba(235, 235, 245, 0.6);
    --metin-ucuncul: rgba(235, 235, 245, 0.3);
    --ayirac: rgba(255, 255, 255, 0.1);
    --vurgu-zemin: rgba(10, 132, 255, 0.18);
    --accent: #0a84ff;
    --golge: 0 10px 40px rgba(0, 0, 0, 0.5);
  }
}

:root[data-tema="dark"] {
  --zemin: #000000;
  --pencere: #1c1c1e;
  --kart: #1c1c1e;
  --kenar-zemin: rgba(28, 28, 30, 0.72);
  --sekme-zemin: rgba(22, 22, 24, 0.86);
  --metin: #f5f5f7;
  --metin-ikincil: rgba(235, 235, 245, 0.6);
  --metin-ucuncul: rgba(235, 235, 245, 0.3);
  --ayirac: rgba(255, 255, 255, 0.1);
  --vurgu-zemin: rgba(10, 132, 255, 0.18);
  --accent: #0a84ff;
  --golge: 0 10px 40px rgba(0, 0, 0, 0.5);
}

/* ── Reset ──────────────────────────────────────────────────────────── */

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  font: 400 var(--satir) / 1.45 var(--yazi);
  color: var(--metin);
  background: var(--zemin);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overscroll-behavior-y: none;
}

[hidden] { display: none !important; }

/* 31: focus must be visible, and never only as a colour change. */
:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* ── Buttons ────────────────────────────────────────────────────────── */

.dugme {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  /* 34: 44px is the floor for anything a thumb has to hit. */
  min-height: 44px;
  padding: 0 20px;
  border: 0;
  border-radius: var(--r-alan);
  font: 600 15px/1 var(--yazi);
  text-decoration: none;
  cursor: pointer;
  transition: opacity var(--gecis) ease, background var(--gecis) ease;
}

.dugme-birincil {
  background: var(--accent);
  color: #fff;
}

.dugme:hover { opacity: 0.88; }
.dugme:active { opacity: 0.74; }

.dugme-kucuk {
  min-height: 32px;
  padding: 0 12px;
  font-size: 13px;
  background: var(--vurgu-zemin);
  color: var(--accent);
}

.ikon-dugme {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border: 0;
  border-radius: var(--r-alan);
  background: transparent;
  color: var(--accent);
  cursor: pointer;
}

.ikon-dugme:hover { background: var(--vurgu-zemin); }

/* The sprite is markup, not a picture. Taking it out of flow here rather
 * than with a style attribute in the HTML is what lets the page's CSP
 * refuse inline styles outright. */
.ikon-deposu {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

/* One rule for every hand-drawn icon, so the sprite stays stroke-only. */
svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Sign-in ────────────────────────────────────────────────────────── */

.giris {
  display: grid;
  place-items: center;
  min-height: 100%;
  padding: 24px;
}

.giris-kart {
  width: 100%;
  max-width: 360px;
  padding: 40px 32px;
  text-align: center;
  background: var(--kart);
  border-radius: var(--r-pencere);
  box-shadow: var(--golge);
}

.giris-mark {
  width: 44px;
  height: 44px;
  color: var(--accent);
  stroke-width: 1.4;
}

.giris-kart h1 {
  margin: 12px 0 4px;
  font: 600 26px/1.2 var(--yazi);
  letter-spacing: -0.015em;
}

.giris-alt {
  margin: 0 0 24px;
  color: var(--metin-ikincil);
  font-size: var(--satir);
}

.giris-kart .dugme { width: 100%; }

.giris-not {
  margin: 20px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: var(--metin-ikincil);
}

/* ── Shell: three panes on a desktop, one column on a phone ─────────── */

.kabuk {
  display: grid;
  height: 100%;
  grid-template-areas: "liste";
  grid-template-columns: 1fr;
}

/* ── Sidebar (46: translucent, coloured dots, no window chrome) ─────── */

.kenar {
  grid-area: kenar;
  display: none;
  flex-direction: column;
  padding: 12px 8px;
  background: var(--kenar-zemin);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-right: 1px solid var(--ayirac);
}

.kenar-ust {
  padding: 4px 10px 12px;
}

.kenar-hesap {
  font: 600 12px/1.3 var(--yazi);
  color: var(--metin-ikincil);
  word-break: break-all;
}

.klasor-liste {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1 1 auto;
  overflow-y: auto;
}

.klasor {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--metin);
  font: 400 var(--ui) / 1 var(--yazi);
  text-align: left;
  cursor: pointer;
}

.klasor:hover { background: var(--ayirac); }

.klasor[aria-current="true"] {
  background: var(--vurgu-zemin);
  color: var(--accent);
  font-weight: 600;
}

.klasor svg { width: 17px; height: 17px; }

.klasor-ad {
  flex: 1 1 auto;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.klasor-sayi {
  font: 600 11px/1 var(--yazi);
  color: var(--metin-ikincil);
  font-variant-numeric: tabular-nums;
}

.kenar-cikis {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  margin-top: 8px;
  padding: 0 10px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--metin-ikincil);
  font: 400 var(--ui) / 1 var(--yazi);
  cursor: pointer;
}

.kenar-cikis:hover { background: var(--ayirac); color: var(--metin); }
.kenar-cikis svg { width: 16px; height: 16px; }

/* ── Toolbar and Large Title ────────────────────────────────────────── */

.liste-panel {
  grid-area: liste;
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: var(--pencere);
  border-right: 1px solid var(--ayirac);
}

.arac-cubugu {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--ayirac);
}

/* 54: a 32px bold Large Title on the phone; 46 wants a quiet 13px
 * toolbar label instead, so the size drops at the desktop breakpoint. */
.buyuk-baslik {
  flex: 1 1 auto;
  margin: 0;
  font: 700 32px/1.15 var(--yazi);
  letter-spacing: -0.02em;
}

.arama-sargi {
  position: relative;
  flex: 1 1 100%;
  display: flex;
  align-items: center;
}

.arama-ikon {
  position: absolute;
  left: 9px;
  width: 16px;
  height: 16px;
  color: var(--metin-ikincil);
  pointer-events: none;
}

.arama {
  width: 100%;
  min-height: 36px;
  padding: 0 10px 0 32px;
  border: 1px solid transparent;
  /* 54 specifies a 10px rounded search field. */
  border-radius: 10px;
  background: var(--ayirac);
  color: var(--metin);
  font: 400 var(--satir) / 1 var(--yazi);
  -webkit-appearance: none;
  appearance: none;
}

.arama::placeholder { color: var(--metin-ikincil); }
.arama:focus { border-color: var(--accent); outline: none; background: var(--kart); }

/* ── Message list (54: inset-grouped cards, 16px from the edge) ─────── */

.liste {
  flex: 1 1 auto;
  min-height: 0;
  margin: 0;
  padding: 12px 16px calc(84px + var(--alt-guvenli));
  list-style: none;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.satir {
  position: relative;
  overflow: hidden;
  border-radius: var(--r-kart);
  background: var(--kart);
  margin-bottom: 8px;
}

.satir-ic {
  display: grid;
  grid-template-columns: 10px 1fr auto;
  gap: 2px 10px;
  width: 100%;
  min-height: 72px;
  padding: 12px 14px;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  font: inherit;
  cursor: pointer;
  transition: transform var(--gecis) ease, background var(--gecis) ease;
}

.satir-ic:hover { background: var(--ayirac); }

.satir[aria-selected="true"] .satir-ic {
  background: var(--vurgu-zemin);
}

/* 31: unread is a dot AND a bold weight, never colour alone. */
.satir-nokta {
  grid-row: 1 / 3;
  align-self: start;
  width: 8px;
  height: 8px;
  margin-top: 5px;
  border-radius: 50%;
  background: transparent;
}

.satir.okunmadi .satir-nokta { background: var(--accent); }
.satir.okunmadi .satir-kimden,
.satir.okunmadi .satir-konu { font-weight: 600; }

.satir-kimden {
  grid-column: 2;
  font-size: var(--satir);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.satir-tarih {
  grid-column: 3;
  grid-row: 1;
  font-size: 12px;
  color: var(--metin-ikincil);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.satir-konu {
  grid-column: 2 / 4;
  font-size: var(--satir);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.satir-onizleme {
  grid-column: 2 / 4;
  /* 46 asks for a two-line preview under the subject. */
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  font-size: 13px;
  color: var(--metin-ikincil);
}

.satir-clip {
  grid-column: 3;
  align-self: end;
  width: 15px;
  height: 15px;
  color: var(--metin-ikincil);
}

.liste-durum {
  margin: 0;
  padding: 12px 16px calc(84px + var(--alt-guvenli));
  text-align: center;
  color: var(--metin-ikincil);
  font-size: 13px;
}

.liste-durum:empty { display: none; }

/* ── Swipe actions (pattern 35) ─────────────────────────────────────── */

.satir-eylemler {
  position: absolute;
  inset: 0 0 0 auto;
  display: flex;
  align-items: stretch;
}

.satir-eylem {
  display: grid;
  place-items: center;
  width: 72px;
  border: 0;
  color: #fff;
  cursor: pointer;
}

.satir-eylem svg { stroke-width: 1.8; }
.satir-eylem-arsiv { background: var(--accent); }
.satir-eylem-sil { background: var(--kirmizi); }

/* ── Reading pane ───────────────────────────────────────────────────── */

.okuma {
  grid-area: okuma;
  display: none;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  background: var(--kart);
}

.okuma-bos {
  flex: 1 1 auto;
  display: grid;
  place-content: center;
  justify-items: center;
  gap: 10px;
  color: var(--metin-ucuncul);
}

.okuma-bos svg { width: 44px; height: 44px; stroke-width: 1.2; }
.okuma-bos p { margin: 0; font-size: var(--satir); }

.okuma-govde {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  min-height: 0;
}

.okuma-ust {
  display: flex;
  align-items: flex-start;
  gap: 4px;
  padding: 12px 20px 14px;
  border-bottom: 1px solid var(--ayirac);
}

.okuma-baslik { min-width: 0; flex: 1 1 auto; }

.okuma-baslik h3 {
  margin: 0 0 3px;
  font: 600 18px/1.3 var(--yazi);
  letter-spacing: -0.01em;
  text-wrap: balance;
}

.okuma-baslik p {
  margin: 0;
  font-size: 13px;
  color: var(--metin-ikincil);
  overflow-wrap: anywhere;
}

.okuma-tarih { font-variant-numeric: tabular-nums; }

.govde-cerceve {
  flex: 1 1 auto;
  width: 100%;
  min-height: 0;
  padding: 0;
  border: 0;
  /* The document inside is sanitised server-side and carries its own
   * CSP; the sandbox attribute in the markup is the third layer. */
  background: transparent;
}

/* ── Bottom tab bar (54 + 34) ───────────────────────────────────────── */

.sekme-cubugu {
  grid-area: sekme;
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: space-around;
  padding-bottom: var(--alt-guvenli);
  background: var(--sekme-zemin);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  /* 54: a thin top border, not a shadow. */
  border-top: 1px solid var(--ayirac);
}

.sekme {
  display: flex;
  flex: 1 1 0;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  min-height: 50px;
  padding: 6px 0;
  border: 0;
  background: transparent;
  color: var(--metin-ikincil);
  font: 500 10px/1 var(--yazi);
  cursor: pointer;
}

.sekme svg { width: 24px; height: 24px; }
.sekme[aria-current="page"] { color: var(--accent); }

/* 54 forbids a floating action button, so "write" is a tab bar item
 * with the accent colour rather than a circle over the content. */
.sekme-birincil { color: var(--accent); }

/* ── Phone view switching ───────────────────────────────────────────── */

.kabuk[data-gorunum="liste"] .liste-panel { display: flex; }
.kabuk[data-gorunum="liste"] .okuma { display: none; }
.kabuk[data-gorunum="okuma"] .liste-panel { display: none; }
.kabuk[data-gorunum="okuma"] .okuma { display: flex; }
.kabuk[data-gorunum="okuma"] .sekme-cubugu { display: none; }

/* A sidebar opened as a sheet on the phone (pattern 38: one layer, a
 * 250–300ms rise, and a visible way to close it). */
.kabuk[data-kenar="acik"] .kenar {
  position: fixed;
  inset: auto 0 0 0;
  z-index: 20;
  display: flex;
  max-height: 72vh;
  padding-bottom: calc(16px + var(--alt-guvenli));
  border-right: 0;
  border-top-left-radius: var(--r-pencere);
  border-top-right-radius: var(--r-pencere);
  box-shadow: var(--golge);
  animation: yukari 280ms cubic-bezier(0.32, 0.72, 0, 1);
}

@keyframes yukari {
  from { transform: translateY(100%); }
  to { transform: translateY(0); }
}

/* ── Desktop: three panes (46) ──────────────────────────────────────── */

@media (min-width: 1024px) {
  .kabuk {
    grid-template-areas: "kenar liste okuma";
    /* 46 asks for a 280px list; 320 gives the two-line preview room
     * without the subject truncating on every row. */
    grid-template-columns: 232px 320px minmax(0, 1fr);
  }

  .kenar { display: flex; }

  /* Both panes are always visible, so the phone's view switch must not
   * apply here or one of them disappears on a wide screen. */
  .kabuk[data-gorunum] .liste-panel,
  .kabuk[data-gorunum] .okuma { display: flex; }
  .kabuk[data-gorunum="okuma"] .liste-panel { display: flex; }

  .kabuk[data-kenar="acik"] .kenar {
    position: static;
    max-height: none;
    border-right: 1px solid var(--ayirac);
    border-radius: 0;
    box-shadow: none;
    animation: none;
    padding-bottom: 12px;
  }

  /* 46: the toolbar label is quiet and inline, not a Large Title. */
  .buyuk-baslik {
    font: 600 var(--ui) / 1 var(--yazi);
    letter-spacing: 0;
    flex: 0 0 auto;
  }

  .arama-sargi { flex: 1 1 auto; max-width: 220px; }
  .arama { min-height: 28px; font-size: var(--ui); }

  .liste { padding: 8px 8px 12px; }

  .satir { margin-bottom: 2px; border-radius: 6px; }

  .satir-ic { min-height: 0; padding: 8px 10px; }

  .satir-kimden, .satir-konu { font-size: var(--ui); }
  .satir-onizleme { font-size: 12px; }

  /* Swipe is a touch gesture; on a pointer device the row actions are
   * reachable from the keyboard and the toolbar instead. */
  .satir-eylemler { display: none; }

  .sekme-cubugu, .yalniz-mobil { display: none; }

  .okuma-ust { padding: 16px 24px; }
}

/* ── Reading actions and attachments ────────────────────────────────── */

.okuma-eylemler {
  display: flex;
  gap: 2px;
  flex: 0 0 auto;
}

.ek-liste {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 12px 20px 0;
  list-style: none;
}

.ek-liste:empty { display: none; }

.ek {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 36px;
  max-width: 100%;
  padding: 0 12px;
  border-radius: 999px;
  background: var(--ayirac);
  color: var(--metin);
  font-size: 12.5px;
  text-decoration: none;
}

.ek:hover { background: var(--vurgu-zemin); color: var(--accent); }
.ek svg { width: 15px; height: 15px; flex: 0 0 auto; }

.ek-ad {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.ek-boy {
  color: var(--metin-ikincil);
  font-variant-numeric: tabular-nums;
  flex: 0 0 auto;
}

.ek-sil {
  display: grid;
  place-items: center;
  width: 22px;
  height: 22px;
  margin-right: -6px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: var(--metin-ikincil);
  cursor: pointer;
}

.ek-sil:hover { color: var(--kirmizi); }
.ek-sil svg { width: 13px; height: 13px; }

/* ── Compose ────────────────────────────────────────────────────────── */

.yazma {
  position: fixed;
  inset: 0;
  z-index: 30;
  display: grid;
  background: rgba(0, 0, 0, 0.28);
}

.yazma-kart {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: var(--kart);
  /* 38: a sheet that rises, 250–300ms, and only ever one layer deep. */
  animation: yukari 280ms cubic-bezier(0.32, 0.72, 0, 1);
}

.yazma-ust {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-bottom: 1px solid var(--ayirac);
}

.yazma-ust h2 {
  flex: 1 1 auto;
  margin: 0;
  font: 600 16px/1.2 var(--yazi);
  text-align: center;
}

.dugme-gonder { min-height: 34px; background: var(--accent); color: #fff; }

.yazma-alanlar {
  flex: 0 0 auto;
  border-bottom: 1px solid var(--ayirac);
}

.yazma-satir {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 0 16px;
  border-bottom: 1px solid var(--ayirac);
}

.yazma-satir:last-child { border-bottom: 0; }

.yazma-etiket {
  flex: 0 0 62px;
  color: var(--metin-ikincil);
  font-size: 13px;
}

.yazma-girdi {
  flex: 1 1 auto;
  min-width: 0;
  height: 42px;
  border: 0;
  background: transparent;
  color: var(--metin);
  font: 400 var(--satir) / 1.3 var(--yazi);
  -webkit-appearance: none;
  appearance: none;
}

.yazma-girdi:focus { outline: none; }
.yazma-girdi::placeholder { color: var(--metin-ucuncul); }

select.yazma-girdi { cursor: pointer; }

.metin-dugme {
  flex: 0 0 auto;
  min-height: 32px;
  padding: 0 8px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: var(--accent);
  font: 500 13px/1 var(--yazi);
  cursor: pointer;
}

.metin-dugme:hover { background: var(--vurgu-zemin); }

.ek-liste-yazma { padding: 12px 16px 0; }

.yazma-govde {
  flex: 1 1 auto;
  min-height: 0;
  width: 100%;
  padding: 14px 16px;
  border: 0;
  background: transparent;
  color: var(--metin);
  font: 400 var(--satir) / 1.55 var(--yazi);
  resize: none;
  -webkit-appearance: none;
  appearance: none;
}

.yazma-govde:focus { outline: none; }

.yazma-alt {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px calc(8px + var(--alt-guvenli));
  border-top: 1px solid var(--ayirac);
}

.yazma-durum {
  flex: 1 1 auto;
  text-align: right;
  color: var(--metin-ikincil);
  font-size: 12px;
}

/* Phone: the sheet is the whole screen. */
.yazma-kart {
  width: 100%;
  height: 100%;
  border-radius: 0;
}

@media (min-width: 1024px) {
  .yazma { place-items: center; padding: 24px; }

  .yazma-kart {
    width: min(680px, 100%);
    height: min(620px, 100%);
    border-radius: var(--r-pencere);
    box-shadow: var(--golge);
    overflow: hidden;
  }

  .yazma-ust h2 { text-align: left; }
}

/* ── Toast ──────────────────────────────────────────────────────────── */

.uyari {
  position: fixed;
  left: 50%;
  bottom: calc(76px + var(--alt-guvenli));
  z-index: 40;
  max-width: calc(100vw - 32px);
  padding: 10px 16px;
  transform: translateX(-50%);
  border-radius: 999px;
  background: var(--metin);
  color: var(--kart);
  font-size: 13px;
  box-shadow: var(--golge);
}

@media (min-width: 1024px) {
  .uyari { bottom: 24px; }
}
