/* İlan Grid ve Kartları */
.ads-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 28px 22px;
  justify-items: center;
  margin-top: 18px;
}
.ad-card-link {
  text-decoration: none;
  color: inherit;
  display: block;
}
.ad-card {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 24px #004d9911;
  overflow: hidden;
  transition: box-shadow 0.2s, transform 0.2s;
  width: 100%;
  max-width: 260px;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  cursor: pointer;
}
.ad-card:hover {
  box-shadow: 0 8px 32px #00b4d822;
  transform: scale(1.03);
}
.ad-card-img {
  width: 100%;
  height: 150px;
  object-fit: cover;
  border-top-left-radius: 16px;
  border-top-right-radius: 16px;
  box-shadow: 0 2px 8px #004d9911;
}
.ad-card-body {
  padding: 16px 14px 18px 14px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}
.ad-card-title {
  font-size: 1.1rem;
  font-weight: bold;
  margin-bottom: 6px;
  color: #222;
}
.ad-card-desc {
  font-size: 0.98rem;
  color: #555;
  margin-bottom: 10px;
}
.ad-card-price {
  font-weight: bold;
  color: #004d99;
  font-size: 1.08rem;
  margin-top: 4px;
}
/* Reset & Base */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Segoe UI', 'Roboto', Arial, sans-serif;
}

body {
  background: linear-gradient(135deg, #e0e7ff 0%, #f5f7fa 100%);
  color: #222;
  min-height: 100vh;
}

/* Navbar */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: linear-gradient(90deg, #004d99 60%, #00b4d8 100%);
  padding: 18px 40px;
  color: #fff;
  box-shadow: 0 4px 24px #004d9922;
  border-bottom-left-radius: 24px;
  border-bottom-right-radius: 24px;
  position: sticky;
  top: 0;
  z-index: 10;
}

.navbar .logo {
  font-size: 2rem;
  font-weight: bold;
  letter-spacing: 2px;
  color: #ffcc00;
  text-shadow: 1px 2px 8px #0002;
  transition: color 0.2s;
}
.navbar .logo:hover {
  color: #fff;
}

.search-box {
  flex: none;
  margin: 0 auto;
  display: flex;
  width: 340px;
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 2px 12px #004d9911;
  overflow: hidden;
  transition: box-shadow 0.2s;
}
.search-box:focus-within {
  box-shadow: 0 4px 24px #00b4d822;
}
.search-box input {
  width: 220px;
  padding: 12px 16px;
  border: none;
  outline: none;
  font-size: 1rem;
  background: transparent;
}
.search-box button {
  padding: 0 24px;
  border: none;
  background: linear-gradient(90deg, #ffcc00 60%, #ffe066 100%);
  color: #004d99;
  cursor: pointer;
  font-weight: bold;
  font-size: 1rem;
  transition: background 0.2s, color 0.2s;
  border-left: 1px solid #eee;
}
.search-box button:hover {
  background: linear-gradient(90deg, #ffe066 60%, #ffcc00 100%);
  color: #222;
}

.auth-buttons button, .auth-buttons a button {
  margin-left: 10px;
  padding: 10px 18px;
  border: none;
  background: linear-gradient(90deg, #ffcc00 60%, #ffe066 100%);
  color: #004d99;
  cursor: pointer;
  border-radius: 8px;
  font-weight: bold;
  font-size: 1rem;
  box-shadow: 0 2px 8px #004d9911;
  transition: background 0.2s, color 0.2s, box-shadow 0.2s;
}
.auth-buttons button:hover, .auth-buttons a button:hover {
  background: linear-gradient(90deg, #ffe066 60%, #ffcc00 100%);
  color: #222;
  box-shadow: 0 4px 16px #ffcc0033;
}
.user-badge {
  background: #004d99;
  color: #fff;
  border-radius: 50%;
  padding: 8px 14px;
  font-weight: bold;
  font-size: 1.1rem;
  margin-right: 8px;
  box-shadow: 0 2px 8px #004d9911;
  border: 2px solid #ffcc00;
  display: inline-block;
  vertical-align: middle;
}

/* Layout */
.container {
  display: flex;
  margin-top: 24px;
  align-items: flex-start;
  gap: 32px;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}

/* Sidebar */
.sidebar {
  width: 270px;
  background: linear-gradient(135deg, #fff 80%, #e0e7ff 100%);
  padding: 28px 18px 28px 24px;
  border-radius: 18px;
  box-shadow: 0 4px 24px #004d9911;
  border-right: 2px solid #e0e7ff;
  height: calc(100vh - 90px);
  overflow-y: auto;
  align-self: flex-start;
  position: sticky;
  left: 0;
  animation: sidebarIn 1s cubic-bezier(.68,-0.55,.27,1.55);
}
@keyframes sidebarIn {
  0% { transform: translateX(-60px); opacity: 0; }
  100% { transform: translateX(0); opacity: 1; }
}
.sidebar h3 {
  margin-top: 15px;
  font-size: 1.2rem;
  color: #004d99;
  letter-spacing: 1px;
  margin-bottom: 10px;
}
.sidebar ul {
  list-style: none;
  margin: 5px 0 18px;
  padding-left: 0;
}
.sidebar ul li {
  margin: 8px 0;
  padding: 8px 12px;
  border-radius: 8px;
  transition: background 0.2s, color 0.2s, transform 0.2s;
  cursor: pointer;
  font-size: 1rem;
  color: #004d99;
}
.sidebar ul li:hover, .sidebar ul li:focus {
  background: #ffcc00;
  color: #222;
  transform: translateX(8px) scale(1.04);
}
.sidebar ul li a {
  color: inherit;
  text-decoration: none;
  display: block;
}

/* Content */
.content {
  flex: 1;
  padding: 32px 0 32px 0;
  min-height: 600px;
  animation: contentIn 1.2s cubic-bezier(.68,-0.55,.27,1.55);
}
@keyframes contentIn {
  0% { transform: translateY(40px); opacity: 0; }
  100% { transform: translateY(0); opacity: 1; }
}
.ads-placeholder, .card {
  background: #fff;
  padding: 32px 24px;
  border-radius: 18px;
  text-align: center;
  box-shadow: 0 4px 24px #004d9911;
  margin-bottom: 24px;
  transition: box-shadow 0.2s, transform 0.2s;
}
.ads-placeholder:hover, .card:hover {
  box-shadow: 0 8px 32px #00b4d822;
  transform: scale(1.01);
}

/* Responsive */
@media (max-width: 1100px) {
  .container {
    flex-direction: column;
    gap: 0;
    max-width: 98vw;
  }
  .sidebar {
    position: static;
    width: 100%;
    height: auto;
    margin-bottom: 24px;
  }
}
@media (max-width: 700px) {
  .navbar {
    flex-direction: column;
    gap: 12px;
    padding: 12px 8px;
    border-radius: 0 0 18px 18px;
  }
  .container {
    padding: 0 4px;
  }
  .sidebar {
    padding: 16px 6px 16px 10px;
    border-radius: 12px;
  }
  .content {
    padding: 12px 0;
  }
}

/* İlan Ekle - Form Styles */
.content .form-card {
  padding: 24px;
  max-width: 860px;
  margin: 0 auto 24px auto;
  background: #fff; /* ensure card bg if overridden elsewhere */
}
.form-title {
  color: #004d99;
  margin-bottom: 16px;
}
.ilan-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.form-group {
  display: flex;
  flex-direction: column;
}
.form-group label {
  font-weight: 600;
  margin-bottom: 6px;
  color: #234;
}
.content .form-control {
  padding: 10px 12px;
  border: 1px solid #d6ddec;
  border-radius: 8px;
  font-size: 1rem;
  background: #fff;
  color: #222;
  width: 100%; /* make inputs full width */
  display: block;
}
.form-control:focus {
  outline: none;
  border-color: #00b4d8;
  box-shadow: 0 4px 18px #00b4d822;
}
.form-row {
  display: flex;
  gap: 12px;
}
.form-row .half { flex: 1 }
.form-actions { margin-top: 8px; display:flex; justify-content:flex-end }
.btn-primary {
  background: linear-gradient(90deg,#ffcc00 60%, #ffe066 100%);
  color: #004d99;
  border: none;
  padding: 10px 20px;
  border-radius: 10px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 6px 20px #004d9911;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 10px 30px #004d9933 }
.error-msg { color: #c02; background:#ffecec; padding:8px 12px; border-radius:8px; margin-bottom:8px }

@media (max-width: 900px) {
  .form-row { flex-direction: column }
  .form-card { padding: 18px }
}

/* Fallback enforcement: ensure ilan form displays correctly even if other CSS loads */
.content .form-card { box-shadow: 0 6px 26px rgba(0,77,153,0.12) !important; border-radius: 12px !important }
.content .form-control { width: 100% !important; box-sizing: border-box !important }
.content .form-title { font-size: 1.5rem !important }


/* Very specific rules for ilan_ekle page to defeat other overrides */
#ilan-ekle-page .form-card { padding: 26px !important; background: #fff !important; border-radius: 12px !important; box-shadow: 0 10px 30px rgba(0,77,153,0.12) !important }
#ilan-ekle-page .form-control { width: 100% !important; display:block !important; padding:10px 12px !important; border-radius:8px !important; border:1px solid #d6ddec !important }
#ilan-ekle-page .form-title { color: #004d99 !important; font-weight:700 !important }
#ilan-ekle-page .ilan-form { gap:12px !important }
#ilan-ekle-page .form-row { gap:12px !important }
#ilan-ekle-page .form-row .half { flex:1 1 0 !important }
#ilan-ekle-page .btn-primary { background: linear-gradient(90deg,#ffcc00 60%, #ffe066 100%) !important; color:#004d99 !important }

/* Image preview thumbnails */
#ilan-ekle-page .image-preview { display:flex; gap:8px; margin-top:8px; flex-wrap:wrap }
#ilan-ekle-page .image-preview .thumb{ width:84px; height:64px; overflow:hidden; border-radius:8px; box-shadow:0 2px 10px rgba(0,0,0,0.08); border:1px solid #e6eef8 }
#ilan-ekle-page .image-preview .thumb img{ width:100%; height:100%; object-fit:cover; display:block }

