/* E-posta ve dernekler — yönetim panelinin kart ve yazı diliyle (yonetim.css üstüne). */
.ep-main { max-width: 1280px; }
.ep-main, .ep-modal { font-family: 'M PLUS Rounded 1c', sans-serif; }
.ep-main *, .ep-modal * { box-sizing: border-box; }
.ep-main [hidden] { display: none !important; }

/* Sekmeler */
.ep-tabs { display: inline-flex; gap: 4px; padding: 4px; border: 1px solid rgba(0, 153, 214, .24); border-radius: 12px; background: rgba(3, 13, 26, .6); }
.ep-tabs button {
  display: inline-flex; align-items: center; gap: 8px; min-height: 42px; padding: 0 20px; border: 0; border-radius: 9px; cursor: pointer;
  font-family: inherit; font-weight: 600; font-size: 14px; color: var(--muted); background: transparent; transition: background .2s, color .2s;
}
.ep-tabs button:hover { color: var(--white); }
.ep-tabs button.on { color: var(--white); background: var(--blue); }
.ep-tabs button.on .yn-count { color: var(--white); border-color: rgba(255, 255, 255, .45); }

/* Yazma görünümü */
.ep-compose { display: grid; grid-template-columns: minmax(0, 480px) minmax(0, 1fr); gap: 28px; align-items: start; margin-top: 36px; }
.ep-form { display: flex; flex-direction: column; gap: 20px; }
.ep-step { display: flex; flex-direction: column; gap: 16px; padding: 26px; }
.ep-step-h { display: flex; align-items: center; gap: 12px; font-family: 'Aleo', serif; font-weight: 700; font-size: 20px; color: var(--white); margin: 0 0 2px; }
.ep-step-h span { display: grid; place-items: center; width: 28px; height: 28px; border-radius: 50%; font-family: 'M PLUS Rounded 1c', sans-serif; font-size: 14px; color: var(--sky); border: 1px solid rgba(0, 153, 214, .5); background: rgba(0, 153, 214, .12); }
.ep-lbl, .ep-f > span { font-weight: 600; font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--sky); }
.ep-f { display: flex; flex-direction: column; gap: 7px; min-width: 0; }
.ep-f em { font-style: normal; font-weight: 300; letter-spacing: .04em; text-transform: none; color: var(--muted); }
.ep-f input, .ep-f textarea, .ep-f select, .ep-search {
  width: 100%; padding: 12px 14px; font-family: inherit; font-weight: 400; font-size: 15px; line-height: 1.4; color: var(--white);
  background: rgba(3, 13, 26, .6); border: 1px solid rgba(0, 153, 214, .3); border-radius: 10px; transition: border-color .2s, box-shadow .2s;
}
.ep-f textarea { min-height: 84px; resize: vertical; line-height: 1.6; }
.ep-f select { appearance: auto; }
.ep-f input::placeholder, .ep-f textarea::placeholder, .ep-search::placeholder { color: rgba(180, 220, 245, .4); }
.ep-f input:focus, .ep-f textarea:focus, .ep-f select:focus, .ep-search:focus { outline: none; border-color: var(--bright); box-shadow: 0 0 0 3px rgba(0, 153, 214, .2); }
.ep-f input[readonly] { color: var(--muted); border-style: dashed; }
.ep-pick input { border-color: rgba(0, 153, 214, .55); background: rgba(0, 115, 175, .14); }
.ep-g2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

.ep-tpl { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.ep-tpl button {
  display: flex; flex-direction: column; gap: 3px; padding: 12px 10px; text-align: start; cursor: pointer; font-family: inherit;
  color: var(--muted); background: rgba(3, 13, 26, .5); border: 1px solid rgba(0, 153, 214, .22); border-radius: 10px; transition: all .2s;
}
.ep-tpl strong { font-weight: 600; font-size: 14px; color: var(--white); }
.ep-tpl small { font-weight: 300; font-size: 12px; }
.ep-tpl button:hover { border-color: var(--bright); }
.ep-tpl button.on { background: rgba(0, 115, 175, .3); border-color: var(--bright); box-shadow: 0 0 0 1px var(--bright) inset; }

.ep-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.ep-chips button {
  min-height: 36px; padding: 0 14px; cursor: pointer; font-family: inherit; font-weight: 400; font-size: 14px;
  color: var(--muted); background: transparent; border: 1px solid rgba(0, 153, 214, .26); border-radius: 999px; transition: all .2s;
}
.ep-chips button:hover { color: var(--white); border-color: var(--bright); }
.ep-chips button.on { color: var(--white); background: var(--blue); border-color: var(--blue); }
.ep-chips i { font-style: normal; font-weight: 600; font-size: 12px; opacity: .75; margin-inline-start: 4px; }

.ep-check { display: flex; align-items: center; gap: 10px; font-weight: 300; font-size: 15px; color: var(--white); cursor: pointer; }
.ep-check input { width: 18px; height: 18px; accent-color: var(--bright); }

.ep-hint { min-height: 22px; font-weight: 400; font-size: 14px; line-height: 1.55; color: #ffcf8a; }
.ep-hint.ok { color: #6fd3ae; }
.ep-hint.err { color: #ff9d9d; }
.ep-send { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.ep-send .yn-btn, .ep-tools .yn-btn { min-height: 46px; padding: 0 18px; font-size: 12px; display: inline-flex; align-items: center; }
.ep-go { min-height: 46px; border: 0; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex: 1 1 200px; }
.ep-go[disabled], .ep-send .yn-btn[disabled] { opacity: .4; cursor: not-allowed; transform: none; box-shadow: none; }
.ep-fine { font-weight: 300; font-size: 13px; line-height: 1.65; color: var(--muted); }

/* Önizleme */
.ep-prev { position: sticky; top: 94px; display: flex; flex-direction: column; border: 1px solid rgba(0, 153, 214, .24); border-radius: 18px; overflow: hidden; background: rgba(3, 13, 26, .55); max-height: calc(100vh - 118px); }
.ep-prev-bar { display: flex; align-items: center; gap: 10px; padding: 12px 16px; border-bottom: 1px solid rgba(0, 153, 214, .16); }
.ep-prev-bar .ep-lbl { margin-inline-end: auto; }
.ep-seg { display: inline-flex; padding: 3px; border: 1px solid rgba(0, 153, 214, .24); border-radius: 9px; }
.ep-seg button { min-height: 30px; padding: 0 12px; border: 0; border-radius: 6px; cursor: pointer; font-family: inherit; font-weight: 600; font-size: 12px; color: var(--muted); background: transparent; }
.ep-seg button.on { color: var(--white); background: var(--blue); }
.ep-meta { display: flex; flex-direction: column; gap: 6px; padding: 12px 16px; border-bottom: 1px solid rgba(0, 153, 214, .16); font-size: 14px; }
.ep-meta div { display: flex; gap: 12px; min-width: 0; }
.ep-meta span { flex: 0 0 44px; font-weight: 300; color: var(--muted); }
.ep-meta b { font-weight: 400; color: var(--white); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ep-stage { flex: 1; overflow-y: auto; padding: 28px 20px; background: #030d1a; }
.ep-stage.light { background: #edf6ff; }
.ep-mail { max-width: 620px; margin: 0 auto; border-radius: 14px; overflow: hidden; box-shadow: 0 8px 48px rgba(0, 0, 0, .28); transition: max-width .25s; }
.ep-mail p { margin-top: 0; }
.ep-stage.phone .ep-mail { max-width: 360px; }

/* Dernek listesi */
.ep-tools { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-top: 36px; }
.ep-search { flex: 1 1 280px; min-height: 46px; }
.ep-tools-r { display: flex; flex-wrap: wrap; gap: 10px; }
.ep-import { cursor: pointer; }
.ep-filter { margin: 18px 0; }
.ep-list { padding: 4px 26px; }
.ep-row { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1.1fr) minmax(0, 1fr) 318px; gap: 20px; align-items: center; padding: 18px 0; border-bottom: 1px solid rgba(0, 153, 214, .14); }
.ep-row:last-child { border-bottom: 0; }
.ep-row > div { display: flex; flex-direction: column; gap: 4px; min-width: 0; font-weight: 300; font-size: 14px; line-height: 1.45; color: var(--muted); overflow-wrap: anywhere; }
.ep-row strong { font-weight: 600; font-size: 16px; color: var(--white); }
.ep-row em { font-style: normal; font-size: 13px; color: rgba(180, 220, 245, .6); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.ep-row a { color: var(--sky); text-decoration: none; }
.ep-row a:hover { text-decoration: underline; }
.ep-row .dim { opacity: .6; }
.ep-row .st {
  align-self: flex-start; min-height: 34px; padding: 0 10px; font-family: inherit; font-weight: 600; font-size: 13px; cursor: pointer;
  color: var(--sky); background: rgba(3, 13, 26, .6); border: 1px solid rgba(0, 153, 214, .4); border-radius: 8px;
}
.ep-row .st-1 { color: #ffcf8a; border-color: rgba(255, 190, 90, .5); }
.ep-row .st-2 { color: #7ed4f7; }
.ep-row .st-3 { color: #c9b3ff; border-color: rgba(170, 140, 255, .5); }
.ep-row .st-4 { color: #6fd3ae; border-color: rgba(52, 211, 153, .5); }
.ep-follow { align-self: flex-start; padding: 3px 10px; border-radius: 999px; font-weight: 600; font-size: 12px; color: #ffcf8a; background: rgba(255, 190, 90, .12); border: 1px solid rgba(255, 190, 90, .4); }
.ep-row .ep-c4 { flex-direction: row; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.ep-c4 .yn-btn { min-height: 40px; padding: 0 14px; }
.ep-c4 .yn-btn.danger { min-width: 64px; justify-content: center; }
.ep-row .st { width: 190px; max-width: 100%; }

/* Pencereler */
.ep-modal { position: fixed; inset: 0; z-index: 9500; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(2, 8, 16, .78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
.ep-modal.open { display: flex; }
.ep-box { width: 100%; max-width: 560px; max-height: calc(100vh - 40px); overflow-y: auto; display: flex; flex-direction: column; gap: 16px; background: #071a2e; }
.ep-box .yn-h2 { margin: 0 0 4px; }
.ep-box-wide { max-width: 820px; }
#htmlCode { max-height: 52vh; overflow: auto; padding: 16px; border-radius: 10px; font-family: ui-monospace, Menlo, monospace; font-size: 12px; line-height: 1.6; color: var(--sky); background: rgba(3, 13, 26, .8); border: 1px solid rgba(0, 153, 214, .2); white-space: pre-wrap; word-break: break-all; }

@media (max-width: 1100px) {
  .ep-compose { grid-template-columns: 1fr; }
  .ep-prev { position: static; max-height: none; }
  .ep-stage { max-height: 80vh; }
  .ep-row { grid-template-columns: 1fr 1fr; }
  .ep-row .ep-c4 { justify-content: flex-start; grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .ep-tabs { width: 100%; }
  .ep-tabs button { flex: 1; justify-content: center; padding: 0 10px; }
  .ep-step { padding: 20px 16px; }
  .ep-g2, .ep-tpl { grid-template-columns: 1fr 1fr; }
  .ep-g2 { grid-template-columns: 1fr; }
  .ep-row { grid-template-columns: 1fr; gap: 12px; }
  .ep-list { padding: 4px 16px; }
  .ep-prev-bar { flex-wrap: wrap; }
  .ep-stage { padding: 16px 10px; }
}
