* { margin:0; padding:0; box-sizing:border-box; }

body{
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  /* background: #ff0000; */
  background: #ffff;
  min-height: 100vh;
  color: #111;
}

.container{ max-width: 1050px; margin: 0 auto; padding: 26px 18px; }

/* Header */
.header{
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(46, 48, 146, 0.808);
  border-bottom: 1px solid rgba(255,255,255,0.16);
}
.header-inner{ display:flex; align-items:center; justify-content:space-between; gap:14px; }
.brand{
  color: #ffffff;
  font-weight: 900;
  text-decoration: none;
  letter-spacing: 0.5px;
  font-size: 1.6rem;
  display: flex;
  align-items: center;
  gap: 8px;
}

.brand::before{
  content: '✓';
  width: 32px;
  height: 32px;
  background: rgba(255, 255, 255, 0.92);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 900;
  color: #2E3092;  /* Mavi renk */
  font-size: 20px;
  font-family: 'Segoe UI', sans-serif;
}

.nav a{
  color: rgba(255, 255, 255, 0.92);
  text-decoration: none;
  margin-left: 14px;
  font-weight: 600;
}
.nav a:hover{ text-decoration:underline; }

/* Logout button: a etiketi gibi dursun */
.nav button.nav-logout{
  background: none;
  border: none;
  padding: 0;
  margin-left: 14px;
  font: inherit;
  color: rgba(255, 255, 255, 0.92);
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  box-shadow: none;
  outline: none;
}

/* hover davranışı da .nav a:hover ile aynı olsun */
.nav button.nav-logout:hover{
  text-decoration: underline;
}

/* Filter box */
.filter{
  background: rgba(46, 48, 146, 0.808);
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 12px;
  padding: 14px;
  margin: 18px 0 14px;
  color: #000000;
}
.filter .row{
  display:flex; flex-wrap:wrap; gap:10px;
}
.filter input, .filter select{
  padding: 10px 10px;
  border-radius: 10px;
  border: 1px solid rgba(255,255,255,0.18);
  background: rgb(255, 255, 255);
  color: #000000;
  outline: none;
}
.filter input::placeholder{ color: rgba(0, 0, 0, 0.7); }
.filter button{
  padding: 10px 14px;
  border-radius: 10px;
  border: none;
  background: rgba(255,255,255,0.92);
  cursor: pointer;
  font-weight: 700;
}
.filter a.reset{
  align-self:center;
  color: rgba(255,255,255,0.92);
  text-decoration:none;
  padding: 8px 10px;
}
.filter a.reset:hover{ text-decoration:underline; }

.hint{ color: rgba(0, 0, 0, 0.92); margin-top:10px; }

/* Grid */
.grid{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-top: 14px;
}

@media (max-width: 980px){
  .grid{ grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 640px){
  .grid{ grid-template-columns: 1fr; }
}

/* Card */
.card{
  background:#fff;
  border-radius: 14px;
  overflow:hidden;
  box-shadow: 0 8px 20px rgba(0,0,0,0.18);
  transition: transform .18s ease, box-shadow .18s ease;
}
.card:hover{
  transform: translateY(-4px);
  box-shadow: 0 14px 30px rgba(0,0,0,0.26);
}
.card .thumb{
  width:100%;
  height: 190px;
  background: #0b1220;
  display:block;
  object-fit: cover;
}
.card .body{ padding: 14px 14px 16px; }
.card .title{
  margin: 2px 0 8px;
  font-size: 1.08rem;
  line-height: 1.25;
}
.card .title a{
  color:#111;
  text-decoration:none;
}
.card .title a:hover{ text-decoration:underline; }

.badges{ display:flex; gap:8px; flex-wrap:wrap; margin-bottom: 10px; }
.badge{
  display:inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  background: #111827;
  color: #fff;
  font-weight: 800;
  font-size: 0.88rem;
}
.badge.soft{
  background: #eef2ff;
  color: #3730a3;
  font-weight: 700;
}

.meta{ color:#555; font-size: 0.95rem; }

/* Footer */
.footer{
  margin-top: 28px;
  padding: 18px 0;
  border-top: 1px solid rgba(255,255,255,0.16);
  background: rgba(46, 48, 146, 0.808);
  color: rgba(255,255,255,0.88);
  text-align:center;
}

/* Detail page */
.detail-head{
  display:flex;
  align-items:flex-start;
  justify-content:space-between;
  gap:14px;
  margin: 10px 0 12px;
  color:#000000;
}
.detail-title{
  font-size: 2rem;
  line-height: 1.15;
  margin-bottom: 10px;
}
.detail-sub{
  color: rgba(0, 0, 0, 0.836);
  font-weight: 600;
}

.panel{
  background: rgba(0, 0, 0, 0.164);
  border-radius: 14px;
  box-shadow: 0 10px 26px rgba(0,0,0,0.22);
  overflow:hidden;
}

.panel-body{ padding: 16px 16px 18px; }

.kv{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  margin-top: 10px;
}
.kv .pill{
  background:#f3f4f6;
  color:#111827;
  padding: 8px 10px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.95rem;
}

/* Gallery */
.gallery-main{
  width:100%;
  max-width: 100%;
  height: 380px;
  object-fit: contain;
  background:#0b1220;
  display:block;
  border-bottom: 1px solid #eee;
}
.gallery-thumbs{
  display:flex;
  gap:10px;
  flex-wrap:wrap;
  padding: 12px 12px 4px;
  background:#fff;
}
.gallery-thumbs img{
  width: 150px;
  height: 110px;
  object-fit: cover;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  cursor: pointer;
  transition: transform .15s ease;
}
.gallery-thumbs img:hover{ transform: translateY(-2px); }

.backlink{
  color: rgba(0, 0, 0, 0.92);
  text-decoration:none;
  font-weight: 800;
}
.backlink:hover{ text-decoration:underline; }

.desc{
  color:#111;
  line-height: 1.7;
  margin-top: 10px;
}

/* ===== Forms (Django as_p) ===== */
.form-grid p{
  margin: 0 0 12px;
}

.form-grid label{
  display:block;
  margin: 0 0 6px;
  font-weight: 800;
  color: rgba(15,23,42,0.9);
}

.form-grid input[type="text"],
.form-grid input[type="number"],
.form-grid input[type="email"],
.form-grid input[type="password"],
.form-grid input[type="url"],
.form-grid textarea,
.form-grid select{
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(15,23,42,0.16);
  background: #fff;
  color: #0f172a;
  outline: none;
}

.form-grid textarea{
  min-height: 120px;
  resize: vertical;
}

.form-grid input:focus,
.form-grid textarea:focus,
.form-grid select:focus{
  border-color: rgba(124,58,237,0.55);
  box-shadow: 0 0 0 3px rgba(124,58,237,0.18);
}

/* Yardım metinleri ve hatalar */
.form-grid .helptext{
  display:block;
  margin-top: 6px;
  color: #64748b;
  font-size: 0.92rem;
}
.form-grid .errorlist{
  list-style: none;
  padding: 10px 12px;
  margin: 0 0 10px;
  border-radius: 12px;
  border: 1px solid rgba(239,68,68,0.28);
  background: rgba(239,68,68,0.08);
  color: #991b1b;
  font-weight: 700;
}

/* File input (çok çirkin gelir, biraz toparlayalım) */
.form-grid input[type="file"]{
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px dashed rgba(15,23,42,0.24);
  background: rgba(248,250,252,0.9);
}

/* Form içi buton hizası */
.form-grid .btn{
  margin-top: 6px;
}

/* =========================
   BUTTON SYSTEM
   ========================= */

/* Varsayılan tüm butonlar */
button,
input[type="submit"],
input[type="button"]{
  appearance: none;
  -webkit-appearance: none;
  border: 1px solid rgba(15,23,42,0.16);
  background: linear-gradient(180deg, #7c3aed, #5b21b6);
  color: #fff;
  font-weight: 800;
  font-size: 0.95rem;
  padding: 10px 16px;
  border-radius: 12px;
  cursor: pointer;
  transition: transform .12s ease, box-shadow .12s ease, filter .12s ease;
  box-shadow: 0 6px 16px rgba(2,6,23,0.28);
}

/* Hover */
button:hover,
input[type="submit"]:hover,
input[type="button"]:hover{
  filter: brightness(1.05);
  box-shadow: 0 10px 22px rgba(2,6,23,0.34);
}

/* Active (basılma hissi) */
button:active,
input[type="submit"]:active,
input[type="button"]:active{
  transform: translateY(1px);
  box-shadow: 0 4px 10px rgba(2,6,23,0.26);
}

/* Focus (erişilebilirlik) */
button:focus-visible,
input[type="submit"]:focus-visible,
input[type="button"]:focus-visible{
  outline: 3px solid rgba(124,58,237,0.35);
  outline-offset: 2px;
}

/* .btn sınıfı (var olanları bozmadan güçlendir) */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: 12px;
  font-weight: 800;
}

/* İkincil buton (iptal, geri, reset vs) */
.btn.secondary,
button.secondary{
  background: #000000;
  color: #ffffff;
  border-color: rgba(15,23,42,0.18);
}

/* Tehlikeli işlem (sil vb.) */
.btn.danger,
button.danger{
  margin-top: 10px;
  background: linear-gradient(180deg, #ef4444, #b91c1c);
  border-color: rgba(239,68,68,0.55);
}

/* Küçük buton */
.btn.small,
button.small{
  padding: 8px 12px;
  font-size: 0.88rem;
}

/* Geniş buton (form submit için çok yakışır) */
.btn.block,
button.block{
  /* width: 100%; */
  background: #000000;
}

/* Disabled */
button:disabled,
input[type="submit"]:disabled{
  opacity: 0.55;
  cursor: not-allowed;
  box-shadow: none;
}

.v2-wrap{
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px;
}

.v2-header{
  margin-bottom: 14px;
}

.v2-title{
  margin: 0;
  font-size: 22px;
  letter-spacing: .2px;
}

.v2-sub{
  margin-top: 6px;
  opacity: .8;
  font-size: 13px;
}

.v2-list{
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.v2-row{
  display: grid;
  grid-template-columns: 140px 1fr 170px;
  gap: 14px;
  align-items: stretch;
  
  text-decoration: none;
  color: inherit;
  background-color: #fff;

  border-radius: 14px;
  padding: 12px;
  border: 1px solid rgba(255,255,255,.10);
  box-shadow: 0 10px 30px rgba(0,0,0,.18);
  transition: transform .14s ease, background .14s ease, border-color .14s ease;
}

.v2-row:hover{
  transform: translateY(-1px);
  background: rgba(255,255,255,.08);
  border-color: rgba(255,255,255,.16);
}

.v2-thumb{
  width: 140px;
  height: 92px;
  border-radius: 12px;
  overflow: hidden;
  background: rgba(0,0,0,.18);
  display: flex;
  align-items: center;
  justify-content: center;
}

.v2-thumb img{
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.v2-thumb-empty{
  font-size: 12px;
  opacity: .75;
}

.v2-main{
  min-width: 0;
  padding-top: 2px;
}

.v2-main-top{
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
}

.v2-row-title{
  font-size: 16px;
  font-weight: 700;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.v2-price{
  font-size: 16px;
  font-weight: 800;
  white-space: nowrap;
}

.v2-meta{
  margin-top: 6px;
  font-size: 13px;
  opacity: .85;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.v2-meta .dot{
  opacity: .55;
}

.v2-desc{
  margin-top: 8px;
  font-size: 13px;
  opacity: .78;
  line-height: 1.35;
}

.v2-side{
  text-align: right;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 8px;
}


.v2-date{
  font-size: 12px;
  opacity: .75;
}

.v2-owner{
  font-size: 12px;
  opacity: .75;
}

.v2-badge{
  align-self: flex-end;
  font-size: 11px;
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255,165,0,.16);
  border: 1px solid rgba(255,165,0,.28);
}

.v2-empty{
  padding: 18px;
  border-radius: 14px;
  background: rgba(255,255,255,.05);
  border: 1px dashed rgba(255,255,255,.18);
  opacity: .85;
}

.v2-pager{
  margin-top: 14px;
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
}

.v2-page{
  text-decoration: none;
  color: inherit;
  padding: 8px 12px;
  border-radius: 12px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.12);
}

.v2-page.current{
  font-weight: 700;
  opacity: .9;
}

/* TODO Table styles*/

/* Tablo bordürleri */
table {
  width: 100%;
  border-collapse: collapse;
  border-spacing: 0px;
  margin-top: 14px;
}

table thead {
  background-color: #2E3092;
  color: #ffffff;
}

table thead th {
  padding: 12px 14px;
  text-align: left;
  border: 1px solid #1a1d52;
  font-weight: 700;
}

table tbody tr {
  border-bottom: 1px solid #e5e7eb;
  transition: background-color .12s ease;
}

table tbody tr:hover {
  background-color: #f3f4f6;
}

table tbody td {
  padding: 12px 14px;
  border: 1px solid #e5e7eb;
}

table a {
  color: #2E3092;
  text-decoration: none;
  font-weight: 600;
}

table a:hover {
  text-decoration: underline;
}

/* TODO end table styles */