/* ==========================================================================
   Delphium Dermaceuticals — tasarım sistemi
   Marka rengi logodan alınmıştır: #305355
   ========================================================================== */

:root {
  /* Marka — bu değerler admin panelindeki ayarlarla ezilebilir */
  --brand:        #305355;
  --brand-dark:   #2C4C4E;
  --brand-darker: #1D3334;
  --brand-light:  #4F8487;
  --brand-pale:   #F2F6F5;
  --brand-pale-2: #DCE7E6;
  --accent:       #C86A41;

  --ink:      #16241F;
  --body:     #4B5A55;
  --muted:    #8A9A95;
  --line:     #DEE7E4;
  --line-soft:#EDF3F1;
  --bg:       #F7FAF9;
  --surface:  #FFFFFF;

  --ok:    #1F8A5B;
  --warn:  #B5761A;
  --err:   #C0392F;
  --info:  #2C6FA8;

  --r-sm: 6px;
  --r:    10px;
  --r-lg: 16px;
  --r-pill: 999px;

  --sh-sm: 0 2px 8px -4px rgba(22, 36, 31, .18);
  --sh:    0 10px 30px -18px rgba(22, 36, 31, .30);
  --sh-lg: 0 24px 60px -28px rgba(22, 36, 31, .38);

  --ease: cubic-bezier(.22, .61, .36, 1);

  --font-head: "Jost", "Futura", -apple-system, "Segoe UI", sans-serif;
  --font-body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --wrap: 1240px;
  --gutter: 24px;
  --header-h: 74px;
}

/* --------------------------------------------------------------- reset --- */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--body);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; height: auto; display: block; }

a { color: var(--brand); text-decoration: none; transition: color .2s var(--ease); }
a:hover { color: var(--brand-light); }

h1, h2, h3, h4, h5 {
  font-family: var(--font-head);
  color: var(--ink);
  font-weight: 500;
  line-height: 1.18;
  margin: 0 0 .6em;
  letter-spacing: -.01em;
}
h1 { font-size: clamp(2rem, 4.2vw, 3.1rem); }
h2 { font-size: clamp(1.55rem, 2.8vw, 2.25rem); }
h3 { font-size: 1.22rem; }
h4 { font-size: 1.02rem; }
p  { margin: 0 0 1.1em; }
p:last-child { margin-bottom: 0; }

hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }

button, input, select, textarea { font: inherit; color: inherit; }

::selection { background: var(--brand-pale-2); color: var(--brand-darker); }

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}

/* --------------------------------------------------------------- düzen --- */

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.wrap--narrow { max-width: 820px; }
.wrap--mid { max-width: 1020px; }

.section { padding: 76px 0; }
.section--sm { padding: 48px 0; }
.section--tight { padding: 34px 0; }
.section--white { background: var(--surface); }
.section--pale { background: var(--brand-pale); }
.section--ink { background: var(--ink); color: rgba(255,255,255,.78); }
.section--ink h1, .section--ink h2, .section--ink h3 { color: #fff; }

.grid { display: grid; gap: 22px; }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--4 { grid-template-columns: repeat(4, 1fr); }
.grid--auto { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); }

.flex { display: flex; }
.between { display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.center { text-align: center; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.row { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }

/* ----------------------------------------------------------- tipografi --- */

.eyebrow {
  font-family: var(--font-head);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .26em;
  text-transform: uppercase;
  color: var(--brand);
  margin: 0 0 .9rem;
}
.section--ink .eyebrow { color: var(--accent); }

.lead { font-size: 1.05rem; color: var(--body); }
.muted { color: var(--muted); }
.small { font-size: .85rem; }
.tiny { font-size: .76rem; }
.strong { font-weight: 600; color: var(--ink); }

.section-head { text-align: center; max-width: 620px; margin: 0 auto 46px; }
.section-head h2 { margin-bottom: .5rem; }
.section-head p { color: var(--muted); margin: 0; }
.section-head--left { text-align: left; margin-left: 0; }

.rule {
  width: 46px; height: 2px; background: var(--brand);
  margin: 0 auto 1.4rem; border-radius: 2px;
}
.section-head--left .rule { margin-left: 0; }

/* ------------------------------------------------------------- butonlar --- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 26px;
  border: 1px solid var(--brand);
  background: var(--brand);
  color: #fff;
  border-radius: var(--r-sm);
  font-family: var(--font-head);
  font-size: .84rem;
  font-weight: 500;
  letter-spacing: .05em;
  cursor: pointer;
  transition: all .22s var(--ease);
  white-space: nowrap;
  text-align: center;
}
.btn:hover { background: var(--brand-dark); border-color: var(--brand-dark); color: #fff; transform: translateY(-1px); box-shadow: var(--sh-sm); }
.btn:active { transform: translateY(0); }
.btn:disabled, .btn.is-disabled { opacity: .5; cursor: not-allowed; transform: none; }

.btn--ghost { background: transparent; color: var(--brand); }
.btn--ghost:hover { background: var(--brand); color: #fff; }

.btn--line { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--line:hover { background: var(--ink); border-color: var(--ink); color: #fff; }

.btn--dark { background: var(--ink); border-color: var(--ink); }
.btn--dark:hover { background: #000; border-color: #000; }

.btn--accent { background: var(--accent); border-color: var(--accent); color: var(--ink); }
.btn--accent:hover { background: var(--ink); border-color: var(--ink); color: #fff; }

.btn--danger { background: var(--err); border-color: var(--err); }
.btn--danger:hover { background: #9E2E25; border-color: #9E2E25; }

.btn--block { width: 100%; }
.btn--lg { padding: 15px 34px; font-size: .92rem; }
.btn--sm { padding: 8px 16px; font-size: .78rem; }
.btn--pill { border-radius: var(--r-pill); }

/* --------------------------------------------------------------- rozet --- */

.badge {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  font-family: var(--font-head);
  background: var(--brand-pale-2);
  color: var(--brand-dark);
  line-height: 1.4;
}
.badge--sale  { background: #FCE9E7; color: var(--err); }
.badge--new   { background: #E6F4EE; color: var(--ok); }
.badge--out   { background: #EFEDF2; color: var(--muted); }
.badge--warn  { background: #FDF1DF; color: var(--warn); }
.badge--info  { background: #E6F0F8; color: var(--info); }
.badge--ok    { background: #E6F4EE; color: var(--ok); }
.badge--solid { background: var(--brand); color: #fff; }

/* --------------------------------------------------------------- form --- */

.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 16px; }
.field > label, .label {
  font-size: .78rem;
  font-weight: 600;
  color: var(--ink);
  letter-spacing: .02em;
}
.field .hint { font-size: .74rem; color: var(--muted); }
.field .err-msg { font-size: .76rem; color: var(--err); }

.input, .select, .textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface);
  font-size: .92rem;
  transition: border-color .18s, box-shadow .18s;
}
.input:focus, .select:focus, .textarea:focus {
  outline: 0;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-pale-2);
}
.input::placeholder, .textarea::placeholder { color: #AEA7B8; }
.input.is-error, .select.is-error { border-color: var(--err); }
.textarea { resize: vertical; min-height: 110px; line-height: 1.65; }
.select { cursor: pointer; appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%238B8397' stroke-width='1.6' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 13px center; padding-right: 34px;
}

.check { display: flex; gap: 9px; align-items: flex-start; cursor: pointer; font-size: .88rem; }
.check input { margin-top: 3px; accent-color: var(--brand); width: 16px; height: 16px; flex: 0 0 auto; }

.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.field-row--3 { grid-template-columns: repeat(3, 1fr); }

/* --------------------------------------------------------------- kart --- */

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r);
  padding: 22px;
}
.card--flat { border: 0; box-shadow: var(--sh-sm); }
.card__head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding-bottom: 14px; margin-bottom: 16px; border-bottom: 1px solid var(--line);
}
.card__head h3 { margin: 0; font-size: 1.02rem; }

/* --------------------------------------------------------------- uyarı --- */

.alert {
  display: flex; gap: 11px; align-items: flex-start;
  padding: 13px 16px; border-radius: var(--r-sm);
  font-size: .88rem; margin-bottom: 16px;
  border: 1px solid transparent;
}
.alert--success { background: #ECF7F1; border-color: #C6E6D6; color: #14603F; }
.alert--error   { background: #FDEEEC; border-color: #F5CFCB; color: #8E271F; }
.alert--info    { background: #EDF3F9; border-color: #CFDFEE; color: #1F5580; }
.alert--warn    { background: #FDF5E7; border-color: #F0DEBC; color: #7A5210; }

/* ------------------------------------------------------------- flash --- */

.flash-stack {
  position: fixed; top: 90px; right: 20px; z-index: 900;
  display: flex; flex-direction: column; gap: 9px; max-width: 340px;
}
.flash {
  padding: 13px 18px; border-radius: var(--r-sm); font-size: .88rem;
  background: var(--surface); box-shadow: var(--sh);
  border-left: 3px solid var(--brand);
  animation: flashIn .35s var(--ease);
}
.flash--success { border-left-color: var(--ok); }
.flash--error   { border-left-color: var(--err); }
.flash--info    { border-left-color: var(--info); }
@keyframes flashIn { from { opacity: 0; transform: translateX(20px); } to { opacity: 1; transform: none; } }

/* --------------------------------------------------------------- tablo --- */

.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); }
.table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.table th {
  text-align: left; padding: 12px 16px; background: var(--brand-pale);
  font-family: var(--font-head); font-size: .74rem; font-weight: 600;
  letter-spacing: .08em; text-transform: uppercase; color: var(--brand-dark);
  white-space: nowrap; border-bottom: 1px solid var(--line);
}
.table td { padding: 13px 16px; border-bottom: 1px solid var(--line-soft); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #FCFBFD; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }

/* ----------------------------------------------------------- sayfalama --- */

.pager { display: flex; gap: 5px; justify-content: center; margin-top: 40px; flex-wrap: wrap; }
.pager a, .pager span {
  min-width: 38px; height: 38px; padding: 0 12px;
  display: inline-flex; align-items: center; justify-content: center;
  border: 1px solid var(--line); border-radius: var(--r-sm);
  background: var(--surface); color: var(--ink); font-size: .86rem;
}
.pager a:hover { border-color: var(--brand); color: var(--brand); }
.pager .is-active { background: var(--brand); border-color: var(--brand); color: #fff; }
.pager .is-gap { border: 0; background: transparent; }

/* --------------------------------------------------------------- boş --- */

.empty {
  text-align: center; padding: 70px 24px; color: var(--muted);
  background: var(--surface); border: 1px dashed var(--line); border-radius: var(--r-lg);
}
.empty svg { color: var(--line); margin: 0 auto 18px; }
.empty h3 { color: var(--ink); margin-bottom: .4rem; }

/* ------------------------------------------------------------ yardımcı --- */

.mt-0{margin-top:0}.mt-1{margin-top:8px}.mt-2{margin-top:16px}.mt-3{margin-top:24px}.mt-4{margin-top:36px}
.mb-0{margin-bottom:0}.mb-1{margin-bottom:8px}.mb-2{margin-bottom:16px}.mb-3{margin-bottom:24px}.mb-4{margin-bottom:36px}
.gap-1{gap:8px}.gap-2{gap:16px}.gap-3{gap:24px}
.w-100{width:100%}
.nowrap{white-space:nowrap}
.text-right{text-align:right}
.text-brand{color:var(--brand)}
.text-err{color:var(--err)}
.text-ok{color:var(--ok)}
.hide{display:none !important}

@media (max-width: 1024px) {
  .grid--4 { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 860px) {
  .section { padding: 54px 0; }
  .grid--3, .grid--4 { grid-template-columns: repeat(2, 1fr); }
  .field-row, .field-row--3 { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  :root { --gutter: 16px; }
  .grid--2, .grid--3, .grid--4, .grid--auto { grid-template-columns: 1fr; }
  .flash-stack { left: 16px; right: 16px; max-width: none; top: 76px; }
}
