:root {
  --bg: #0a0b0d; --yuzey: #121418; --yuzey2: #191c22; --cizgi: #262a32; --cizgi2: #343944;
  --yazi: #ecebe6; --soluk: #8d929c; --soluk2: #5f646e;
  --altin: #e2b354; --altin2: #f3d48e; --altin-zemin: rgba(226, 179, 84, .12);
  --yesil: #5cc58e; --yesil-zemin: rgba(92, 197, 142, .12);
  --mavi: #74a9ff; --mavi-zemin: rgba(116, 169, 255, .12);
  --mor: #b49cff;
  --r: 18px; --r2: 12px;
  --gov: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  --bas: 'Barlow Condensed', 'Inter', system-ui, sans-serif;
  color-scheme: dark;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--yazi); font-family: var(--gov); font-size: 15px; line-height: 1.45; }
body { min-height: 100dvh; overscroll-behavior-y: none; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: var(--altin); }
#uygulama { max-width: 560px; margin: 0 auto; min-height: 100dvh; }
#ekran { padding: calc(env(safe-area-inset-top) + 18px) 16px calc(96px + env(safe-area-inset-bottom)); }

/* Alt menü */
#alt { position: fixed; left: 0; right: 0; bottom: 0; display: flex; justify-content: center; gap: 2px; padding: 8px 8px calc(8px + env(safe-area-inset-bottom));
  background: rgba(10, 11, 13, .88); backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px); border-top: 1px solid var(--cizgi); z-index: 10; }
#alt a { flex: 1; max-width: 108px; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 6px 0; text-decoration: none; color: var(--soluk2); font-size: 11px; font-weight: 500; border-radius: 12px; }
#alt a svg { width: 23px; height: 23px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
#alt a.aktif { color: var(--altin); }
#alt a.aktif svg { filter: drop-shadow(0 0 8px rgba(226, 179, 84, .45)); }

/* Başlıklar */
.ust { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin: 4px 0 18px; }
.ust h1 { font-family: var(--bas); font-weight: 700; font-size: 34px; letter-spacing: .02em; line-height: 1; margin: 0; text-transform: uppercase; }
.ust .alt-baslik { color: var(--soluk); font-size: 13px; margin-top: 6px; }
.rozet { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600; padding: 5px 10px; border-radius: 999px; background: var(--altin-zemin); color: var(--altin2); white-space: nowrap; }
h2 { font-family: var(--bas); font-weight: 600; font-size: 15px; letter-spacing: .12em; text-transform: uppercase; color: var(--soluk); margin: 26px 2px 10px; }

/* Kartlar */
.kart { background: var(--yuzey); border: 1px solid var(--cizgi); border-radius: var(--r); padding: 16px; margin-bottom: 12px; }
.kart.vurgu { background: linear-gradient(160deg, #1b1812 0%, var(--yuzey) 55%); border-color: #3a3222; }
.kart h3 { margin: 0 0 4px; font-size: 14px; font-weight: 600; }
.ikili { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ikili .kart { margin-bottom: 0; }
.soluk { color: var(--soluk); } .kucuk { font-size: 12.5px; }
.buyuk-sayi { font-family: var(--bas); font-weight: 700; font-size: 40px; line-height: 1; letter-spacing: .01em; }
.orta-sayi { font-family: var(--bas); font-weight: 600; font-size: 26px; line-height: 1; }
.birim { font-size: 14px; color: var(--soluk); font-family: var(--gov); font-weight: 500; margin-left: 3px; }
.satir { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bosluk { height: 10px; }

/* Alfred brif */
.alfred-not { display: flex; gap: 12px; }
.alfred-yuz { flex: none; width: 38px; height: 38px; border-radius: 12px; background: linear-gradient(145deg, #2b2416, #15130f); border: 1px solid #4a3d22; display: grid; place-items: center; font-family: var(--bas); font-weight: 700; color: var(--altin); font-size: 18px; }
.alfred-not p { margin: 0; white-space: pre-wrap; }
.alfred-not .kim { font-size: 12px; color: var(--altin); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; margin-bottom: 4px; }
.iskelet { height: 12px; border-radius: 6px; background: linear-gradient(90deg, var(--yuzey2), var(--cizgi), var(--yuzey2)); background-size: 200% 100%; animation: parla 1.4s infinite; margin: 6px 0; }
@keyframes parla { to { background-position: -200% 0; } }

/* Minimum üçlü */
.minimum { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; }
.min { background: var(--yuzey); border: 1px solid var(--cizgi); border-radius: var(--r); padding: 14px 10px 12px; text-align: center; cursor: pointer; transition: transform .12s, border-color .2s; user-select: none; }
.min:active { transform: scale(.97); }
.min .halka { width: 58px; height: 58px; margin: 0 auto 8px; position: relative; }
.min .halka svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.min .halka .ic { position: absolute; inset: 0; display: grid; place-items: center; font-family: var(--bas); font-weight: 700; font-size: 17px; }
.min .ad { font-size: 12.5px; font-weight: 600; }
.min .alt { font-size: 11.5px; color: var(--soluk); }
.min.tamam { border-color: rgba(92, 197, 142, .45); background: linear-gradient(180deg, rgba(92, 197, 142, .08), var(--yuzey)); }
.seri-satir { display: flex; align-items: center; gap: 10px; margin-top: 10px; padding: 12px 14px; border-radius: var(--r2); background: var(--yuzey2); font-size: 13.5px; }
.seri-satir b { font-family: var(--bas); font-size: 22px; color: var(--altin); }
.noktalar { display: flex; gap: 5px; margin-left: auto; }
.noktalar i { width: 9px; height: 9px; border-radius: 50%; background: var(--cizgi2); }
.noktalar i.t { background: var(--yesil); } .noktalar i.k { background: var(--altin); }

/* Çubuklar */
.cubuk { height: 8px; border-radius: 99px; background: var(--yuzey2); overflow: hidden; margin: 10px 0 6px; }
.cubuk > i { display: block; height: 100%; border-radius: 99px; background: var(--altin); transition: width .5s; }
.cubuk.mavi > i { background: var(--mavi); } .cubuk.yesil > i { background: var(--yesil); }

/* Düğmeler */
.dugme { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--cizgi2); background: var(--yuzey2); border-radius: 12px; padding: 10px 14px; font-weight: 600; font-size: 14px; cursor: pointer; min-height: 44px; }
.dugme:active { transform: scale(.97); }
.dugme.ana { background: var(--altin); color: #17130a; border-color: var(--altin); }
.dugme.ince { min-height: 36px; padding: 6px 12px; font-size: 13px; }
.dugme.tam { width: 100%; }
.dugme[disabled] { opacity: .5; pointer-events: none; }
.dugmeler { display: flex; gap: 8px; flex-wrap: wrap; }
.adim { display: flex; align-items: center; gap: 8px; margin-top: 10px; }
.adim .dugme { flex: 1; min-height: 40px; padding: 6px; }
.secim { display: flex; gap: 6px; background: var(--yuzey2); padding: 4px; border-radius: 12px; }
.secim button { flex: 1; border: 0; background: transparent; padding: 8px; border-radius: 9px; font-size: 13px; font-weight: 600; color: var(--soluk); cursor: pointer; }
.secim button.aktif { background: var(--cizgi2); color: var(--yazi); }

/* Formlar */
.alan { width: 100%; background: var(--yuzey2); border: 1px solid var(--cizgi2); border-radius: 12px; padding: 12px 14px; outline: none; min-height: 46px; }
.alan:focus { border-color: var(--altin); }
textarea.alan { resize: vertical; min-height: 70px; }
label.etiket { display: block; font-size: 12.5px; color: var(--soluk); margin: 10px 2px 6px; }
.giris-sayi { display: flex; gap: 8px; align-items: stretch; }
.giris-sayi .alan { font-family: var(--bas); font-size: 22px; font-weight: 600; text-align: center; }

/* Listeler */
.liste { display: flex; flex-direction: column; }
.oge { display: flex; align-items: center; gap: 12px; padding: 12px 2px; border-bottom: 1px solid var(--cizgi); }
.oge:last-child { border-bottom: 0; }
.oge .ad { flex: 1; min-width: 0; }
.oge .ad div:first-child { font-weight: 500; overflow: hidden; text-overflow: ellipsis; }
.oge .deger { text-align: right; font-family: var(--bas); font-weight: 600; font-size: 18px; white-space: nowrap; }
.oge .x { border: 0; background: none; color: var(--soluk2); font-size: 18px; padding: 6px; cursor: pointer; }
.cipler { display: flex; gap: 8px; overflow-x: auto; padding: 2px 0 4px; scrollbar-width: none; }
.cipler::-webkit-scrollbar { display: none; }
.cip { flex: none; border: 1px solid var(--cizgi2); background: var(--yuzey2); border-radius: 999px; padding: 8px 12px; font-size: 13px; cursor: pointer; white-space: nowrap; }
.cip small { color: var(--soluk); margin-left: 4px; }

/* Protein halkası */
.halka-buyuk { display: flex; align-items: center; gap: 18px; }
.halka-buyuk .h { width: 112px; height: 112px; position: relative; flex: none; }
.halka-buyuk .h svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.halka-buyuk .h .ic { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; }

/* Grafik */
.grafik { width: 100%; height: auto; display: block; margin-top: 8px; }
.grafik text { fill: var(--soluk2); font-size: 10px; font-family: var(--gov); }

/* Sohbet */
.sohbet { display: flex; flex-direction: column; gap: 10px; padding-bottom: 130px; }
.balon { max-width: 88%; padding: 11px 14px; border-radius: 16px; white-space: pre-wrap; word-wrap: break-word; }
.balon.yunus { align-self: flex-end; background: var(--altin); color: #17130a; border-bottom-right-radius: 6px; }
.balon.alfred { align-self: flex-start; background: var(--yuzey); border: 1px solid var(--cizgi); border-bottom-left-radius: 6px; }
.balon.alfred ul { margin: 6px 0; padding-left: 18px; white-space: normal; }
.yazma { position: fixed; left: 0; right: 0; bottom: calc(68px + env(safe-area-inset-bottom)); padding: 10px 16px; background: linear-gradient(180deg, transparent, var(--bg) 30%); z-index: 9; }
.yazma-ic { max-width: 528px; margin: 0 auto; display: flex; gap: 8px; align-items: flex-end; }
.yazma textarea { flex: 1; min-height: 46px; max-height: 140px; resize: none; }
.yaziyor { display: inline-flex; gap: 4px; }
.yaziyor i { width: 6px; height: 6px; border-radius: 50%; background: var(--soluk); animation: zipla 1s infinite; }
.yaziyor i:nth-child(2) { animation-delay: .15s; } .yaziyor i:nth-child(3) { animation-delay: .3s; }
@keyframes zipla { 50% { transform: translateY(-4px); opacity: .5; } }

/* Ego kartı */
.ego-bas { text-align: center; padding: 26px 16px 22px; background: radial-gradient(circle at 50% 0%, rgba(226, 179, 84, .18), transparent 60%), var(--yuzey); }
.ego-bas .ad { font-family: var(--bas); font-size: 52px; font-weight: 700; letter-spacing: .14em; line-height: 1; color: var(--altin2); }
.ego-bas .soz { font-style: italic; color: var(--soluk); margin-top: 10px; }
.karsi { display: grid; grid-template-columns: 1fr 1fr; gap: 1px; background: var(--cizgi); border-radius: var(--r2); overflow: hidden; }
.karsi div { background: var(--yuzey2); padding: 10px 12px; font-size: 13px; }
.karsi .b { font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; color: var(--soluk); background: var(--yuzey); }
.karsi .b.w { color: var(--altin); }
ol.kurallar { margin: 0; padding-left: 20px; } ol.kurallar li { margin: 6px 0; }
.faz { display: flex; gap: 8px; }
.faz div { flex: 1; padding: 10px; border-radius: var(--r2); background: var(--yuzey2); border: 1px solid var(--cizgi); font-size: 12px; }
.faz div.simdi { border-color: var(--altin); background: var(--altin-zemin); }
.faz b { display: block; font-family: var(--bas); font-size: 16px; }
table.hafta { width: 100%; border-collapse: collapse; font-size: 13px; }
table.hafta td, table.hafta th { padding: 9px 4px; border-bottom: 1px solid var(--cizgi); text-align: left; }
table.hafta th { color: var(--soluk); font-weight: 500; font-size: 12px; }
table.hafta td:last-child { text-align: right; font-weight: 600; }

/* Giriş */
.giris { min-height: 80dvh; display: flex; flex-direction: column; justify-content: center; gap: 14px; }
.giris .logo { font-family: var(--bas); font-weight: 700; font-size: 60px; letter-spacing: .2em; color: var(--altin2); text-align: center; }

/* Tost */
#tost { position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); background: var(--yuzey2); border: 1px solid var(--cizgi2); padding: 10px 16px; border-radius: 12px; font-size: 13.5px; opacity: 0; pointer-events: none; transition: .25s; z-index: 30; max-width: calc(100% - 32px); }
#tost.acik { opacity: 1; transform: translate(-50%, 0); }

/* Alt sayfa (sheet) */
.perde { position: fixed; inset: 0; background: rgba(0, 0, 0, .6); z-index: 20; display: flex; align-items: flex-end; justify-content: center; animation: belir .2s; }
.sayfa { width: 100%; max-width: 560px; max-height: 88dvh; overflow-y: auto; background: var(--yuzey); border: 1px solid var(--cizgi2); border-bottom: 0; border-radius: 22px 22px 0 0; padding: 18px 16px calc(20px + env(safe-area-inset-bottom)); animation: kay .25s; }
.sayfa .tutac { width: 40px; height: 4px; border-radius: 4px; background: var(--cizgi2); margin: -6px auto 14px; }
@keyframes belir { from { opacity: 0; } } @keyframes kay { from { transform: translateY(40px); } }
.foto-onizleme { width: 100%; max-height: 220px; object-fit: cover; border-radius: var(--r2); margin-bottom: 10px; }
.kalem { display: grid; grid-template-columns: 1fr 70px 62px; gap: 6px; align-items: center; margin-bottom: 6px; }
.kalem .alan { min-height: 40px; padding: 8px 10px; font-size: 13.5px; }
.kalem .alan[type=number] { text-align: center; }
.uyari { font-size: 12.5px; color: var(--altin2); background: var(--altin-zemin); padding: 10px 12px; border-radius: 10px; }
