/* OpusOpt web - masaustu uygulamasiyla ayni kurumsal renkler (Styles.xaml) */
:root {
    --opt-ana: #22506E;
    --opt-ana-koyu: #183A52;
    --opt-ana-acik: #E8EFF4;
    --opt-yesil: #3E9E7A;
    --opt-yesil-koyu: #328366;
    --opt-turuncu: #E8913A;
    --opt-kirmizi: #E04C4C;
    --opt-zemin: #EEF0F3;
    --opt-kart: #FFFFFF;
    --opt-cizgi: #DDE1E6;
    --opt-yazi: #1A1D21;
    --opt-soluk: #7A828C;
    --bs-primary: #22506E;
    --bs-primary-rgb: 34, 80, 110;
    --bs-success: #3E9E7A;
    --bs-success-rgb: 62, 158, 122;
    --bs-body-color: #1A1D21;
    --bs-body-bg: #EEF0F3;
    --bs-font-sans-serif: "Segoe UI", system-ui, -apple-system, Roboto, "Noto Sans", "Helvetica Neue", Arial, "Microsoft YaHei", "PingFang SC", "Hiragino Sans", "Yu Gothic", "Noto Sans CJK SC", "Noto Sans Arabic", Tahoma, sans-serif;
}

html, body { height: 100%; }
body { background: var(--opt-zemin); color: var(--opt-yazi); font-size: .925rem; display: flex; flex-direction: column; }
main { flex: 1 0 auto; }
a { color: var(--opt-ana); }
a:hover { color: var(--opt-ana-koyu); }

.btn-primary { --bs-btn-bg: var(--opt-ana); --bs-btn-border-color: var(--opt-ana); --bs-btn-hover-bg: var(--opt-ana-koyu); --bs-btn-hover-border-color: var(--opt-ana-koyu); --bs-btn-active-bg: var(--opt-ana-koyu); --bs-btn-disabled-bg: var(--opt-ana); --bs-btn-disabled-border-color: var(--opt-ana); }
.btn-success { --bs-btn-bg: var(--opt-yesil); --bs-btn-border-color: var(--opt-yesil); --bs-btn-hover-bg: var(--opt-yesil-koyu); --bs-btn-hover-border-color: var(--opt-yesil-koyu); --bs-btn-active-bg: var(--opt-yesil-koyu); --bs-btn-disabled-bg: var(--opt-yesil); --bs-btn-disabled-border-color: var(--opt-yesil); }
.btn-outline-primary { --bs-btn-color: var(--opt-ana); --bs-btn-border-color: var(--opt-ana); --bs-btn-hover-bg: var(--opt-ana); --bs-btn-hover-border-color: var(--opt-ana); --bs-btn-active-bg: var(--opt-ana); }
.text-primary { color: var(--opt-ana) !important; }
.text-success { color: var(--opt-yesil) !important; }
.text-soluk { color: var(--opt-soluk) !important; }
.bg-primary { background-color: var(--opt-ana) !important; }
.form-check-input:checked { background-color: var(--opt-yesil); border-color: var(--opt-yesil); }
.form-control:focus, .form-select:focus { border-color: #7FA6BF; box-shadow: 0 0 0 .2rem rgba(34, 80, 110, .15); }

/* ---------- Ust menu ---------- */
.opt-nav { background: var(--opt-ana); box-shadow: 0 1px 0 rgba(0,0,0,.08); }
.opt-nav .navbar-brand { color: #fff; font-weight: 700; letter-spacing: .2px; display: flex; align-items: center; gap: .5rem; }
.opt-nav .navbar-brand img { height: 30px; width: auto; background: #fff; border-radius: 6px; padding: 2px; }
.opt-nav .nav-link { color: rgba(255,255,255,.82); font-weight: 500; }
.opt-nav .nav-link:hover, .opt-nav .nav-link.active { color: #fff; }
.opt-nav .navbar-toggler { border-color: rgba(255,255,255,.3); }
.opt-nav .navbar-toggler-icon { filter: invert(1); }
.opt-rozet-pro { background: linear-gradient(135deg, #3E9E7A, #2E8A9E); color: #fff; font-size: .7rem; font-weight: 700; padding: .2rem .5rem; border-radius: 1rem; letter-spacing: .4px; }
.opt-rozet-ucretsiz { background: rgba(255,255,255,.18); color: #fff; font-size: .7rem; font-weight: 600; padding: .2rem .5rem; border-radius: 1rem; }
.opt-avatar { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; background: #fff; }
.opt-avatar-harf { width: 28px; height: 28px; border-radius: 50%; background: var(--opt-yesil); color: #fff; display: inline-flex; align-items: center; justify-content: center; font-weight: 700; font-size: .8rem; }

.opt-duyuru { background: #FFF6E8; border-bottom: 1px solid #F2D6B0; color: #6B4A1A; font-size: .85rem; }

/* ---------- Kart ---------- */
.opt-kart { background: var(--opt-kart); border: 1px solid var(--opt-cizgi); border-radius: 10px; }
.opt-kart-baslik { font-weight: 600; font-size: .95rem; padding: .65rem .9rem; border-bottom: 1px solid var(--opt-cizgi); display: flex; align-items: center; gap: .5rem; }
.opt-sayfa-baslik { font-weight: 700; font-size: 1.35rem; color: var(--opt-yazi); }

/* ---------- Hesap uygulamasi ---------- */
.opt-app { display: flex; gap: 12px; padding: 12px; min-height: calc(100vh - 56px); }
.opt-sol { width: 520px; min-width: 380px; max-width: 46vw; display: flex; flex-direction: column; gap: 10px; }
.opt-sag { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 10px; }
@media (max-width: 991.98px) {
    .opt-app { flex-direction: column; padding: 8px; }
    .opt-sol { width: 100%; max-width: none; min-width: 0; }
}

/* Ortak arac dugmesi: hepsi ayni yukseklik, ikon + yazi ortali */
.opt-btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; height: 32px; padding: 0 12px; line-height: 1;
    font-size: .84rem; font-weight: 500; white-space: nowrap; background: #fff; border: 1px solid #CDD4DB; color: var(--opt-yazi); border-radius: 6px; }
.opt-btn:hover { background: #F2F6F9; border-color: #B4BFC9; color: var(--opt-yazi); }
.opt-btn svg { flex: none; }
.opt-btn { flex: none; }
.opt-btn.btn-primary { background: var(--bs-primary); border-color: var(--bs-primary); color: #fff; }
.opt-btn.btn-primary:hover { filter: brightness(1.08); color: #fff; }
.opt-btn-kare { width: 32px; padding: 0; }

/* Proje bilgileri karti */
.opt-bolum-baslik.sabit { cursor: default; }
.opt-baslik-ikon { color: var(--bs-primary); display: inline-flex; }
.opt-proje-govde { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 10px; padding: 10px; align-items: end; }
.opt-alan label { display: block; font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .3px; color: var(--opt-soluk); margin-bottom: 3px; }
.opt-alan .form-control { height: 32px; border-color: #CDD4DB; }
.opt-proje-butonlar { grid-column: 1 / -1; display: flex; gap: 6px; justify-content: flex-end; }
@media (max-width: 420px) { .opt-proje-govde { grid-template-columns: 1fr; } .opt-proje-butonlar > .btn { flex: 1; } }
.btn-hesapla { font-weight: 700; padding-left: 1.2rem; padding-right: 1.2rem; }

.opt-bolum { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 10px; overflow: hidden; }
.opt-bolum-baslik { display: flex; align-items: center; gap: 8px; padding: 7px 10px; background: #F6F8FA; border-bottom: 1px solid var(--opt-cizgi); font-weight: 600; cursor: pointer; user-select: none; }
.opt-bolum-baslik .sayac { font-weight: 500; color: var(--opt-soluk); font-size: .8rem; }
.opt-bolum-baslik .ok { margin-inline-start: auto; transition: transform .15s; color: var(--opt-soluk); }
.opt-bolum.kapali .opt-bolum-baslik .ok { transform: rotate(-90deg); }
.opt-bolum.kapali .opt-bolum-govde { display: none; }
.opt-bolum-arac { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px 10px; border-bottom: 1px solid #EEF0F3; align-items: center; }

/* Hizli kenar bandi secimi (parca araclarinin altinda, kendi satirinda) */
.opt-bant-satiri { display: flex; align-items: center; gap: 6px; padding: 6px 10px; background: #FAFBFC; border-bottom: 1px solid #EEF0F3; }
.opt-bant-satiri label { font-size: .72rem; font-weight: 600; text-transform: uppercase; letter-spacing: .3px; color: var(--opt-soluk); margin: 0; white-space: nowrap; }
.opt-bant-satiri .form-select { height: 32px; width: auto; min-width: 150px; max-width: 220px; border-color: #CDD4DB; }
.opt-bant-ipucu { font-size: .74rem; color: var(--opt-soluk); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }

.opt-tablo-kap { max-height: 46vh; overflow: auto; }
table.opt-tablo { width: 100%; border-collapse: separate; border-spacing: 0; font-size: .85rem; }
table.opt-tablo th { position: sticky; top: 0; background: #fff; z-index: 2; font-weight: 600; color: var(--opt-soluk); font-size: .75rem; text-transform: uppercase; letter-spacing: .3px; padding: 5px 4px; border-bottom: 1px solid var(--opt-cizgi); white-space: nowrap; }
table.opt-tablo td { padding: 3px 2px; border-bottom: 1px solid #F0F2F4; vertical-align: middle; }
table.opt-tablo td.no { color: var(--opt-soluk); font-size: .75rem; text-align: center; width: 28px; }
table.opt-tablo tbody tr:hover td { background: #F8FAFC; }
/* Giris hucreleri: her zaman gorunur kutu (bos olanin nereye yazilacagi belli olsun) */
table.opt-tablo input[type=text], table.opt-tablo input[type=number], table.opt-tablo select {
    width: 100%; height: 28px; border: 1px solid #D3DAE1; background: #fff; padding: 3px 6px; border-radius: 4px; font-size: .85rem; min-width: 0;
    color: var(--opt-yazi); box-shadow: inset 0 1px 1px rgba(16, 24, 40, .04); }
table.opt-tablo input:hover, table.opt-tablo select:hover { border-color: #AEB9C4; }
table.opt-tablo input:focus, table.opt-tablo select:focus { outline: none; border-color: var(--bs-primary); background: #fff; box-shadow: 0 0 0 3px rgba(34, 80, 110, .15); }
table.opt-tablo input.hatali { border-color: var(--opt-kirmizi); background: #FFF5F5; }
table.opt-tablo input.sayi { text-align: end; }
/* Yeni satir: kesikli cerceveli, acik yesil — "buraya yazin" */
table.opt-tablo tr.bos td { background: #F5FAF7; }
table.opt-tablo tr.bos td.no { color: var(--opt-yesil); font-weight: 700; font-size: .9rem; }
table.opt-tablo tr.bos input { border-style: dashed; border-color: #9CCBB6; background: #fff; }
table.opt-tablo tr.bos input::placeholder { color: #6E9E88; }
table.opt-tablo .sil { border: 0; background: transparent; color: #B6BCC3; padding: 2px 6px; border-radius: 4px; }
table.opt-tablo .sil:hover { color: var(--opt-kirmizi); background: #FDEEEE; }
.col-olcu { width: 74px; } .col-adet { width: 56px; } .col-kal { width: 54px; } .col-dondur { width: 34px; text-align: center; } .col-bant { width: 46px; } .col-sil { width: 28px; }

/* Damar (cevrilebilir) dugmesi */
.dondur { border: 1px solid #E2E6EA; background: #fff; width: 28px; height: 26px; border-radius: 5px; display: inline-flex; align-items: center; justify-content: center; color: var(--opt-yesil); cursor: pointer; }
.dondur.kapali { color: var(--opt-turuncu); background: #FFF6E8; border-color: #F2D6B0; }

/* Mini kenar bandi secici */
.bant-mini { cursor: pointer; display: block; margin: auto; }
.bant-mini rect.govde { fill: #F4F6F8; stroke: #C9CED4; }
.bant-mini line.kenar { stroke: #D8DCE0; stroke-width: 2.2; }
.bant-mini line.kenar.var { stroke: var(--opt-yesil); stroke-width: 4; }
.bant-mini line.vur { stroke: transparent; stroke-width: 9; }

/* Secenekler */
.opt-secenek { display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; padding: 10px 12px; }
.opt-secenek label.form-label { font-size: .78rem; color: var(--opt-soluk); margin-bottom: 2px; }
.opt-secenek .tam { grid-column: 1 / -1; }
@media (max-width: 575.98px) { .opt-secenek { grid-template-columns: 1fr; } }

/* Sonuc alani */
.opt-sonuc-bos { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 48px 20px; color: var(--opt-soluk); min-height: 420px; }
.opt-sonuc-bos h2 { color: var(--opt-yazi); font-size: 1.35rem; font-weight: 700; }
.opt-adimlar { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; margin-top: 18px; }
.opt-adim { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 10px; padding: 12px 14px; width: 190px; text-align: start; }
.opt-adim b { display: block; color: var(--opt-ana); font-size: 1.1rem; }

.opt-ozet { display: grid; grid-template-columns: repeat(auto-fit, minmax(130px, 1fr)); gap: 8px; }
.opt-ozet .kutu { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 10px; padding: 10px 12px; position: relative; }
.opt-ozet .kutu .e { font-size: .72rem; text-transform: uppercase; letter-spacing: .4px; color: var(--opt-soluk); font-weight: 600; }
.opt-ozet .kutu .d { font-size: 1.45rem; font-weight: 700; line-height: 1.2; }
.opt-ozet .kutu.ana .d { color: var(--opt-ana); }
.opt-ozet .kutu.yesil .d { color: var(--opt-yesil); }
.opt-ozet .kutu.turuncu .d { color: var(--opt-turuncu); }
.kilitli-deger { filter: blur(5px); user-select: none; }
.kilit-ikon { color: var(--opt-turuncu); }

.opt-cizimler { display: grid; grid-template-columns: repeat(auto-fill, minmax(330px, 1fr)); gap: 10px; }
.opt-cizim { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 10px; overflow: hidden; display: flex; flex-direction: column; }
.opt-cizim-ust { display: flex; align-items: center; gap: 8px; padding: 7px 10px; border-bottom: 1px solid #EEF0F3; font-size: .85rem; }
.opt-cizim-ust .tekrar { background: var(--opt-ana); color: #fff; border-radius: 1rem; padding: 0 .55rem; font-weight: 700; font-size: .8rem; }
.opt-cizim-ust .verim { margin-inline-start: auto; color: var(--opt-yesil); font-weight: 600; }
.opt-cizim-svg { padding: 8px; cursor: zoom-in; background: #FCFCFD; }
.opt-cizim-svg svg { width: 100%; height: auto; display: block; }
.opt-cizim.kilitli .opt-cizim-svg { cursor: pointer; position: relative; }
.opt-cizim.kilitli .opt-cizim-svg svg { filter: blur(6px) grayscale(.4); opacity: .55; }
.opt-kilit-ortu { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 10px; }
.opt-kilit-ortu .ikon { width: 46px; height: 46px; border-radius: 50%; background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.12); display: flex; align-items: center; justify-content: center; color: var(--opt-turuncu); }
.opt-kilit-ortu b { color: var(--opt-yazi); }

.opt-ilerleme { padding: 40px 20px; text-align: center; }
.opt-ilerleme .sayac { font-size: 2.2rem; font-weight: 700; color: var(--opt-ana); font-variant-numeric: tabular-nums; }
.opt-donen { width: 54px; height: 54px; border: 5px solid #DCE6EE; border-top-color: var(--opt-yesil); border-radius: 50%; animation: dondur 1s linear infinite; margin: 0 auto 14px; }
@keyframes dondur { to { transform: rotate(360deg); } }

.opt-rapor-butonlari .btn { display: inline-flex; align-items: center; gap: 6px; }
.btn .kilit { color: var(--opt-turuncu); }

/* Buyuk cizim penceresi */
.opt-buyuk-svg svg { width: 100%; height: auto; max-height: 72vh; }
.opt-renk { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: middle; }

/* Giris / form sayfalari */
.opt-giris-kap { max-width: 440px; margin: 40px auto; }
/* Google Client ID girilmemisken: pasif Google dugmesi */
.opt-google-kapali { display: flex; margin: 0 auto; align-items: center; justify-content: center; gap: 10px; width: 100%; max-width: 320px; height: 40px;
    border: 1px solid #DADCE0; border-radius: 20px; background: #fff; color: #3C4043; font-weight: 500; font-size: .92rem; opacity: .6; cursor: not-allowed; }
.opt-ayrac { display: flex; align-items: center; gap: 10px; color: var(--opt-soluk); font-size: .8rem; margin: 16px 0; }
.opt-ayrac::before, .opt-ayrac::after { content: ""; flex: 1; height: 1px; background: var(--opt-cizgi); }
.g_id_signin { display: flex; justify-content: center; min-height: 44px; }

/* Fiyatlar */
.opt-plan { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 14px; padding: 22px; height: 100%; display: flex; flex-direction: column; position: relative; }
.opt-plan.one-cikan { border: 2px solid var(--opt-yesil); box-shadow: 0 6px 20px rgba(62,158,122,.15); }
.opt-plan .etiket { position: absolute; top: -12px; inset-inline-start: 50%; transform: translateX(-50%); background: var(--opt-yesil); color: #fff; font-size: .72rem; font-weight: 700; padding: 3px 12px; border-radius: 1rem; white-space: nowrap; }
[dir=rtl] .opt-plan .etiket { transform: translateX(50%); }
.opt-plan .fiyat { font-size: 2rem; font-weight: 800; color: var(--opt-ana); }
.opt-ozellik { list-style: none; padding: 0; margin: 0; }
.opt-ozellik li { padding: 5px 0; display: flex; gap: 8px; align-items: flex-start; }
.opt-ozellik .evet { color: var(--opt-yesil); flex-shrink: 0; }
.opt-ozellik .hayir { color: #C2C7CD; flex-shrink: 0; }
.opt-karsilastir td, .opt-karsilastir th { vertical-align: middle; }

/* Odeme */
.opt-iban { font-family: Consolas, "Courier New", monospace; font-size: 1.1rem; letter-spacing: .5px; background: #F6F8FA; border: 1px dashed #C9CED4; border-radius: 8px; padding: 10px 12px; word-break: break-all; }
.opt-referans { font-family: Consolas, monospace; font-size: 1.5rem; font-weight: 800; color: var(--opt-turuncu); letter-spacing: 1px; }

footer.opt-alt { background: #fff; border-top: 1px solid var(--opt-cizgi); color: var(--opt-soluk); font-size: .82rem; }
footer.opt-alt a { color: var(--opt-soluk); text-decoration: none; }
footer.opt-alt a:hover { color: var(--opt-ana); }

/* Yonetim */
.yonetim-menu .list-group-item.active { background: var(--opt-ana); border-color: var(--opt-ana); }
.yonetim-kutu { background: #fff; border: 1px solid var(--opt-cizgi); border-radius: 10px; padding: 14px; }
.yonetim-kutu .d { font-size: 1.6rem; font-weight: 800; color: var(--opt-ana); }
.yonetim-kutu .e { color: var(--opt-soluk); font-size: .8rem; text-transform: uppercase; letter-spacing: .3px; font-weight: 600; }
.grafik-cubuk { display: flex; align-items: flex-end; gap: 3px; height: 120px; }
.grafik-cubuk div { flex: 1; background: var(--opt-yesil); border-radius: 3px 3px 0 0; min-height: 2px; position: relative; }
.grafik-cubuk.mavi div { background: var(--opt-ana); }

.toast-container { z-index: 2000; }
[dir=rtl] .opt-tablo input.sayi { text-align: start; }

@media print {
    .opt-nav, .opt-sol, .opt-arac, footer, .opt-rapor-butonlari { display: none !important; }
}

/* Malzeme sutunlari yalnizca 'malzemeyi dikkate al' acikken */
.malzeme-gizli .malzeme-sutun { display: none; }


/* Dar ekranda tablolar yatay kaydirilir; aciklama sutunu sikismasin */
@media (max-width: 575.98px) { table.opt-tablo { min-width: 560px; } .opt-cizimler { grid-template-columns: 1fr; } }

