/* ── Renk Sistemi ── */
:root {
  --color-pending:  #f59e0b;
  --color-label:    #3b82f6;
  --color-packaged: #f97316;
  --color-shipped:  #10b981;
  --color-rush:     #ef4444;
  --color-gift:     #22c55e;
}

/* ── Sipariş Grid ── */
.order-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 24px;
}
@media (max-width: 768px) {
  .order-grid { grid-template-columns: 1fr; }
}

/* ── Bölüm Başlıkları ── */
.section-heading-new {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  margin: 28px 0 14px;
  font-size: 18px;
  font-weight: 800;
  color: #2c1a0e;
  border-left: 5px solid var(--section-color, #ccc);
  background: color-mix(in srgb, var(--section-color, #ccc) 10%, white);
  border-radius: 0 8px 8px 0;
}
.section-heading-new .section-count {
  font-size: 13px;
  font-weight: 700;
  color: white;
  background: var(--section-color, #ccc);
  padding: 3px 12px;
  border-radius: 20px;
}
/* Kargoya Hazır — belirgin turuncu bant */
.section-heading-packaged {
  --section-color: var(--color-packaged);
  border-left-width: 7px;
  font-size: 20px;
}
/* Taşımada — belirgin mavi bant */
.section-heading-shipped {
  --section-color: #3b82f6;
  border-left-width: 7px;
  font-size: 20px;
  color: #1e3a5f;
}
.section-heading-shipped .section-count {
  background: #3b82f6;
}
/* Bölümler arası ayırıcı */
.section-divider {
  border: none;
  border-top: 2px dashed #e5e7eb;
  margin: 32px 0;
}

/* ── Özet Çubuğu ── */
.summary-bar {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  background: white;
  border-radius: 10px;
  padding: 10px 16px;
  margin-bottom: 16px;
  box-shadow: 0 1px 4px rgba(0,0,0,.08);
}
.summary-bar a {
  text-decoration: none;
  color: inherit;
  font-size: 14px;
  font-weight: 700;
  padding: 4px 12px;
  border-radius: 20px;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  gap: 4px;
}
.summary-bar a:hover { opacity: 0.8; }

/* ── Yeni Sipariş Kartı ── */
.new-order-card {
  background: white;
  border-radius: 10px;
  box-shadow: 0 2px 8px rgba(0,0,0,.08);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  position: relative;
  border: 1.5px solid #e8ddd4;
}
.new-order-card.is-rush {
  border: 3px solid var(--color-rush);
}
.new-order-card.is-gift {
  border-left: 5px solid var(--color-gift);
}
.card-stripe {
  height: 5px;
  width: 100%;
}
.card-top {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px 6px;
  flex-wrap: wrap;
}
.card-flag { font-size: 24px; line-height: 1; }
.card-customer { font-size: 15px; font-weight: 700; color: #2c1a0e; flex: 1; min-width: 0; }
.card-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; flex-shrink: 0; margin-left: auto; border: 2px solid #e8ddd6; box-shadow: 0 2px 6px rgba(0,0,0,0.12); }
.card-internal-no {
  font-size: 16px;
  font-weight: 900;
  color: #fff;
  background: #c0392b;
  border-radius: 6px;
  padding: 3px 10px;
  letter-spacing: 0.5px;
}
.card-product {
  padding: 2px 14px 4px;
  font-size: 13px;
  color: #555;
}
.card-atelier-note {
  margin: 4px 14px;
  padding: 6px 10px;
  background: #fffbe6;
  border: 1.5px solid #f5a623;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 600;
  color: #7a4f00;
}
.card-gift-warn {
  margin: 4px 14px;
  padding: 5px 10px;
  background: #fff8e1;
  border: 1.5px solid #f9a825;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 700;
  color: #5d4037;
}
.card-rush-badge {
  display: inline-block;
  background: var(--color-rush);
  color: white;
  font-size: 11px;
  font-weight: 800;
  padding: 2px 8px;
  border-radius: 10px;
  letter-spacing: 0.03em;
}
.card-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-top: 1px solid #f0ece8;
  margin-top: auto;
}
.card-btn-main {
  flex: 1;
  background: #f47a2b;
  color: white;
  border: none;
  border-radius: 8px;
  padding: 9px 14px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  display: inline-block;
}
.card-btn-main:hover { background: #d4651b; color: white; }
.card-btn-icon {
  background: white;
  border: 1.5px solid #d0ccc8;
  border-radius: 8px;
  padding: 8px 10px;
  font-size: 16px;
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
  line-height: 1;
}
.card-btn-icon:hover { background: #f5f5f5; }
.card-details { padding: 0 14px 10px; display: none; }
.card-details.open { display: block; }
.card-expand-btn {
  width: 100%;
  background: none;
  border: none;
  border-top: 1px dashed #e0dbd6;
  padding: 6px;
  font-size: 12px;
  color: #888;
  cursor: pointer;
  text-align: center;
}
.card-expand-btn:hover { color: #444; }

/* ── Header Yeni ── */
.header-top {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.header-search {
  flex: 1;
  min-width: 160px;
  max-width: 320px;
  padding: 7px 12px;
  border: 1.5px solid #5a3a22;
  border-radius: 20px;
  background: rgba(255,255,255,0.1);
  color: white;
  font-size: 14px;
}
.header-search::placeholder { color: rgba(255,255,255,0.55); }
.header-search:focus { outline: none; background: rgba(255,255,255,0.18); }
.header-bell {
  position: relative;
  font-size: 20px;
  cursor: pointer;
  color: white;
  text-decoration: none;
}
.header-bell-badge {
  position: absolute;
  top: -4px;
  right: -6px;
  background: var(--color-rush);
  color: white;
  font-size: 10px;
  font-weight: 800;
  border-radius: 10px;
  padding: 1px 5px;
  min-width: 16px;
  text-align: center;
}
.header-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,0.4);
  cursor: pointer;
}
.header-avatar-initials {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #5a3a22;
  color: white;
  font-size: 14px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  border: 2px solid rgba(255,255,255,0.4);
}
.header-profile-wrap { position: relative; }
.header-profile-dropdown {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.15);
  min-width: 160px;
  z-index: 1000;
  overflow: hidden;
}
.header-profile-dropdown.open { display: block; }
.header-profile-dropdown a,
.header-profile-dropdown button {
  display: block;
  width: 100%;
  padding: 10px 16px;
  text-align: left;
  font-size: 14px;
  color: #2c1a0e;
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
}
.header-profile-dropdown a:hover,
.header-profile-dropdown button:hover { background: #f5f5f5; }
.header-admin-dropdown { position: relative; }
.header-admin-dropdown > button {
  background: none;
  border: none;
  color: white;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
  opacity: 0.9;
  padding: 0;
}
.header-admin-dropdown > button:hover { opacity: 1; }
.header-admin-dropdown .admin-menu {
  display: none;
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  background: white;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(0,0,0,.15);
  min-width: 180px;
  z-index: 1000;
  overflow: hidden;
}
.header-admin-dropdown .admin-menu.open { display: block; }
.header-admin-dropdown .admin-menu a,
.header-admin-dropdown .admin-menu button {
  display: block;
  width: 100%;
  padding: 10px 16px;
  font-size: 14px;
  color: #2c1a0e;
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  text-align: left;
}
.header-admin-dropdown .admin-menu a:hover,
.header-admin-dropdown .admin-menu button:hover { background: #f5f5f5; }
.btn-new-order {
  background: #f47a2b;
  color: white;
  border: none;
  border-radius: 20px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  font-family: inherit;
  white-space: nowrap;
}
.btn-new-order:hover { background: #d4651b; }

/* ── Drawer ── */
.drawer-overlay {
  display: none;
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  inset: 0;
  background: rgba(0,0,0,0.4);
  z-index: 900;
}
.drawer-overlay.open { display: block; }
.drawer-panel {
  position: fixed;
  top: 0;
  right: -420px;
  width: 400px;
  max-width: 95vw;
  height: 100%;
  background: white;
  z-index: 901;
  box-shadow: -4px 0 24px rgba(0,0,0,.15);
  transition: right 0.3s ease;
  display: flex;
  flex-direction: column;
  padding: 24px;
}
.drawer-panel.open { right: 0; }
.drawer-title {
  font-size: 20px;
  font-weight: 800;
  margin-bottom: 20px;
  color: #2c1a0e;
}
.drawer-close {
  position: absolute;
  top: 16px;
  right: 16px;
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
  color: #888;
}
.drawer-close:hover { color: #2c1a0e; }

* { box-sizing: border-box; margin: 0; padding: 0; }
body { font-family: -apple-system, sans-serif; background: #f7f3ee; color: #222; }
header { background: #2c1a0e; color: white; padding: 16px 24px; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
header h1 { font-size: 20px; }
main { max-width: 1200px; margin: 24px auto; padding: 0 16px; }
h2 { margin-bottom: 16px; font-size: 18px; }
.order-list { display: flex; flex-direction: column; gap: 16px; margin-bottom: 16px; }
.order-card { background: #fffdf9; border: 1px solid #e8ddd4; border-radius: 8px; padding: 20px; box-shadow: 0 2px 8px rgba(44,26,14,.07); }
.order-card.done { border-left: 4px solid #4caf50; }
.order-header { display: flex; align-items: center; gap: 12px; margin-bottom: 8px; flex-wrap: wrap; }
.order-id { color: #888; font-size: 13px; }
.badge { background: #e8f5e9; color: #2e7d32; font-size: 12px; padding: 2px 8px; border-radius: 12px; }
.items { margin-bottom: 12px; }
.item { display: flex; gap: 10px; font-size: 14px; padding: 4px 0; flex-wrap: wrap; }
.sku { font-weight: 600; }
.size { color: #555; }
.qty { background: #eee; padding: 1px 6px; border-radius: 4px; }
.personal { font-style: normal; font-size: 14px; font-weight: 700; color: #5a2d00; background: white; border: 1.5px solid #f47a2b; border-radius: 7px; padding: 4px 12px; display: inline-block; }
.empty { color: #888; padding: 16px 0; }
.btn { display: inline-block; background: #f47a2b; color: white; padding: 10px 20px; border-radius: 8px; text-decoration: none; border: none; cursor: pointer; font-size: 15px; transition: background 0.2s; }
.btn:hover { background: #d4651b; }
.btn-secondary { display: inline-block; background: #ddd; color: #333; padding: 10px 20px; border-radius: 8px; text-decoration: none; border: none; cursor: pointer; font-size: 15px; margin-left: 8px; transition: background 0.2s; }
.field { margin-bottom: 16px; }
label { display: block; font-size: 14px; font-weight: 600; margin-bottom: 6px; }
input[type=number], input[type=file], textarea { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 6px; font-size: 15px; }
select { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 6px; font-size: 15px; }
.actions { margin-top: 8px; }
.order-summary { background: #fff8f0; border: 1px solid #f47a2b; border-radius: 6px; padding: 12px; margin-bottom: 20px; }
.order-summary p { margin-bottom: 6px; font-size: 14px; }
.success-box { background: white; border-radius: 8px; padding: 32px; text-align: center; box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.success-box h2 { font-size: 24px; color: #2e7d32; margin-bottom: 12px; }
.success-box p { margin-bottom: 20px; color: #555; }
/* Login */
.login-wrap { display: flex; justify-content: center; padding-top: 48px; }
.login-card { background: white; border-radius: 8px; padding: 32px; box-shadow: 0 1px 6px rgba(0,0,0,.12); width: 100%; max-width: 360px; }
.login-card h2 { margin-bottom: 20px; }
.flash-error { background: #fdecea; color: #b71c1c; padding: 10px 14px; border-radius: 6px; margin-bottom: 16px; font-size: 14px; }
.flash-warning { background: #fff3e0; color: #e65100; border: 3px solid #f57c00; border-radius: 10px; padding: 16px 20px; margin-bottom: 20px; font-size: 17px; font-weight: 700; display: flex; align-items: center; gap: 12px; box-shadow: 0 4px 16px rgba(245,124,0,.25); animation: flash-shake 0.4s ease; }
@keyframes flash-shake {
  0%,100% { transform: translateX(0); }
  20% { transform: translateX(-6px); }
  40% { transform: translateX(6px); }
  60% { transform: translateX(-4px); }
  80% { transform: translateX(4px); }
}
.btn-full { width: 100%; text-align: center; display: block; }
input[type=text], input[type=password] { width: 100%; padding: 10px; border: 1px solid #ccc; border-radius: 6px; font-size: 15px; }

/* Nav */
nav { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.nav-link { color: white; text-decoration: none; font-size: 14px; opacity: 0.9; background: none; border: none; cursor: pointer; padding: 0; font-family: inherit; }
.nav-link:hover { opacity: 1; text-decoration: underline; }
.nav-link-danger { opacity: 0.6; font-size: 12px; }
.nav-link-danger:hover { opacity: 1; color: #ffaaaa; }
.nav-user { font-size: 13px; opacity: 0.75; }

/* Status badges */
.status-badge { font-size: 12px; padding: 3px 10px; border-radius: 16px; font-weight: 700; }
.status-badge.status-pending         { background: #f0f0f0; color: #888; }
.status-badge.status-received        { background: #1565c0; color: #fff; }
.status-badge.status-in_production   { background: #16a34a; color: #fff; }
.status-badge.status-production_done { background: #7c3aed; color: #fff; }
.status-badge.status-embroidery_done { background: #7c3aed; color: #fff; }
.status-badge.status-shipped         { background: #374151; color: #fff; }

/* Order card border + background by status */
.order-card.status-pending         { border: 2px solid #ccc; }
.order-card.status-received        { border: 3px solid #1565c0; background: #dbeafe; }
.order-card.status-in_production   { border: 3px solid #16a34a; background: #dcfce7; }
.order-card.status-production_done { border: 3px solid #7c3aed; background: #ede9fe; }
.order-card.status-embroidery_done { border: 3px solid #7c3aed; background: #ede9fe; }
.order-card.status-shipped         { border: 3px solid #374151; background: #f3f4f6; }

/* Embroidery badge */
.emb-badge { background: #fce4ec; color: #880e4f; font-size: 12px; padding: 2px 8px; border-radius: 12px; }

/* Status update form */
.status-update { margin: 10px 0; }
.btn-sm { padding: 8px 14px; font-size: 13px; }

/* Log details */
.log-details { margin-top: 8px; font-size: 13px; }
.log-details summary { cursor: pointer; color: #888; }
.log-entry { display: flex; gap: 10px; padding: 4px 0; border-bottom: 1px solid #f0f0f0; flex-wrap: wrap; }
.log-time { color: #aaa; }
.log-note { font-style: italic; color: #555; }

/* Pending card — desktop: yatay, mobil: dikey */
.pending-card { display: flex; gap: 14px; align-items: flex-start; }
.pending-card .pending-actions { display: flex; flex-direction: column; gap: 8px; align-items: flex-end; justify-content: center; flex-shrink: 0; margin-left: auto; align-self: center; }

/* Mobile */
@media (max-width: 600px) {
    main { padding: 0 10px; margin: 16px auto; }
    .btn { padding: 12px 18px; font-size: 16px; }
    .order-card { padding: 14px; }
    header h1 { font-size: 17px; }
    .header-logo { height: 30px; }
    .header-brand-text { font-size: 14px; }
    .pending-card { flex-direction: column; }
    .pending-card img, .pending-card > div:first-child { width: 100% !important; height: 180px !important; border-radius: 10px; }
    .pending-card .pending-actions { flex-direction: row; align-items: center; justify-content: flex-start; margin-left: 0; align-self: auto; width: 100%; }
}

/* Section headings with top spacing */
.section-heading { margin-top: 32px; font-size: 22px; color: #2c1a0e; padding-bottom: 8px; border-bottom: 2px solid #c9a882; }

/* Worker panel */
.order-card-link { text-decoration: none; color: inherit; display: block; }
.stage-buttons { display: flex; flex-direction: column; gap: 10px; margin-top: 8px; }
.btn-stage { display: block; width: 100%; padding: 14px; font-size: 16px; background: #f0f0f0; color: #333; border: 2px solid #ddd; border-radius: 8px; cursor: pointer; text-align: center; }
.btn-stage:hover { background: #e0e0e0; }
.btn-stage-active { background: #f47a2b; color: white; border-color: #f47a2b; }

/* User management */
.user-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 24px; }
.user-card { background: white; border-radius: 8px; padding: 14px 18px; box-shadow: 0 1px 3px rgba(0,0,0,.1); display: flex; gap: 12px; align-items: center; flex-wrap: wrap; }
.user-date { color: #aaa; font-size: 12px; }
.status-badge.status-admin { background: #e8eaf6; color: #283593; }
.status-badge.status-worker { background: #f3e5f5; color: #6a1b9a; }
.btn-danger { background: #fdecea; color: #b71c1c; border: none; padding: 6px 12px; border-radius: 6px; cursor: pointer; font-size: 13px; }
.btn-danger:hover { background: #ffcdd2; }
.btn-success { background: #f47a2b; color: white; padding: 10px 20px; border-radius: 8px; text-decoration: none; border: none; cursor: pointer; font-size: 15px; transition: background 0.2s; }
.btn-success:hover { background: #d4651b; }

/* Order card typography */
.order-header strong { font-size: 18px; }
.item-title { font-style: italic; font-size: 13px; color: #555; }

/* Drop zone */
.drop-zone { border: 2px dashed #c9a882; border-radius: 8px; padding: 20px 16px; text-align: center; background: #fffdf9; display: flex; flex-direction: column; align-items: center; gap: 10px; cursor: pointer; transition: border-color 0.2s, background 0.2s; }
.drop-zone-over { border-color: #f47a2b; background: #fff8f0; }
#drop-label { color: #888; font-size: 14px; }

/* Adres uyuşmazlık uyarısı */
.mismatch-warning { background: #fff3e0; border: 3px solid #f57c00; border-radius: 12px; padding: 18px 20px; margin: 16px 0; display: flex; gap: 16px; align-items: flex-start; box-shadow: 0 4px 16px rgba(245,124,0,.2); animation: flash-shake 0.4s ease; }
.mismatch-icon { font-size: 36px; line-height: 1; flex-shrink: 0; }
.mismatch-title { font-size: 18px; font-weight: 800; color: #e65100; margin-bottom: 6px; }
.mismatch-body { font-size: 14px; color: #5d3a00; line-height: 1.6; }

/* Etiket Oluştur — sipariş özet kartı */
.order-detail-card { background: #fffdf9; border: 1px solid #e8ddd4; border-left: 5px solid #f47a2b; border-radius: 12px; display: flex; gap: 0; overflow: hidden; box-shadow: 0 2px 10px rgba(44,26,14,.09); margin-bottom: 8px; }
.order-detail-img-col { display: flex; flex-direction: column; justify-content: flex-start; padding: 16px 12px 16px 16px; flex-shrink: 0; }
.order-detail-img { width: 130px; height: 130px; object-fit: cover; border-radius: 10px; border: 2px solid #e0d4c8; }
.order-detail-img-empty { width: 130px; height: 130px; background: #f5ede4; border-radius: 10px; border: 2px dashed #e0d4c8; }
.order-detail-info { flex: 1; padding: 16px 20px 16px 8px; min-width: 0; }
.order-detail-section { margin-bottom: 12px; padding-bottom: 10px; border-bottom: 1px solid #f0e8e0; font-size: 14px; color: #444; line-height: 1.6; }
.order-detail-section:last-child { border-bottom: none; margin-bottom: 0; }
.order-detail-section-title { font-size: 12px; font-weight: 700; color: #aaa; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 6px; }
.order-detail-item { margin-bottom: 8px; }

@media (max-width: 600px) {
  .order-detail-card { flex-direction: column; }
  .order-detail-img-col { flex-direction: row; align-items: center; gap: 12px; padding-bottom: 0; }
  .order-detail-img, .order-detail-img-empty { width: 90px; height: 90px; }
}

/* Etiket Oluşturulacak kart */
.label-card { background: #fffdf9; border: 1px solid #e8ddd4; border-left: 5px solid #f47a2b; border-radius: 10px; display: flex; gap: 0; overflow: hidden; box-shadow: 0 2px 8px rgba(44,26,14,.07); }
.label-thumb { width: 110px; height: 110px; object-fit: cover; flex-shrink: 0; align-self: center; margin: 14px; border-radius: 8px; border: 1px solid #e0d4c8; }
.label-thumb-empty { width: 110px; height: 110px; background: #f5ede4; flex-shrink: 0; align-self: center; margin: 14px; border-radius: 8px; }
.label-body { flex: 1; padding: 14px 16px 14px 4px; min-width: 0; }
.label-header { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.label-order-no { font-size: 22px; font-weight: 900; color: #f47a2b; background: #fff3e0; padding: 2px 12px; border-radius: 8px; border: 2px solid #ffcc80; letter-spacing: 0.02em; }
.label-customer { font-size: 18px; font-weight: 700; color: #2c1a0e; }
.label-etsy-id { font-size: 12px; color: #aaa; }
.label-item { margin-bottom: 6px; }
.label-item-title { font-size: 13px; color: #555; font-style: italic; line-height: 1.4; }
.label-sku { background: #f5f5f5; color: #555; font-size: 12px; font-weight: 600; padding: 3px 8px; border-radius: 5px; border: 1px solid #ddd; }
.label-actions { margin-top: 12px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }

@media (max-width: 600px) {
  .label-thumb, .label-thumb-empty { width: 80px; height: 80px; margin: 10px; }
  .label-order-no { font-size: 18px; }
}

/* Üretim Takibi kartı */
.prod-card { background: #fffdf9; border: 1px solid #e8ddd4; border-radius: 10px; display: flex; gap: 0; overflow: hidden; box-shadow: 0 2px 8px rgba(44,26,14,.07); }
.prod-card-received        { border: 3px solid #1565c0; background: #dbeafe; }
.prod-card-in_production   { border: 3px solid #16a34a; background: #dcfce7; }
.prod-card-production_done { border: 3px solid #7c3aed; background: #ede9fe; }
.prod-card-shipped         { border: 3px solid #374151; background: #f3f4f6; }
.prod-card-delivered       { border: 3px solid #15803d; background: #dcfce7; }
.prod-thumb { width: 100px; height: 100px; object-fit: cover; flex-shrink: 0; align-self: center; margin: 12px; border-radius: 8px; border: 1px solid #e0d4c8; }
.prod-thumb-empty { width: 100px; height: 100px; background: #f0ebe4; flex-shrink: 0; align-self: center; margin: 12px; border-radius: 8px; }
.prod-body { flex: 1; padding: 12px 14px 10px; min-width: 0; }
.prod-card-photo { width: 160px; height: 160px; flex-shrink: 0; border-left: 2px solid rgba(44,26,14,0.12); align-self: center; }
.prod-card-badge { position: absolute; top: 0; right: 0; background: #2c1a0e; color: white; font-size: 28px; font-weight: 900; padding: 8px 22px; border-radius: 0 0 0 14px; letter-spacing: 0.03em; z-index: 2; }
.prod-header { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.prod-order-no { font-size: 20px; font-weight: 900; color: #2c1a0e; background: #f5ede4; padding: 2px 10px; border-radius: 7px; border: 2px solid #e0c9b0; letter-spacing: 0.02em; }
.prod-customer { font-size: 18px; color: #2c1a0e; font-weight: 700; }
.prod-item { margin-bottom: 8px; }
.prod-item-title { font-size: 13px; color: #555; font-style: italic; }
.prod-status-form { margin: 10px 0 6px; }
.prod-select { padding: 8px 10px; border: 1px solid #ccc; border-radius: 6px; font-size: 14px; background: white; }
.prod-note-input { flex: 1; min-width: 100px; padding: 8px 10px; border: 1px solid #ccc; border-radius: 6px; font-size: 14px; }

@media (max-width: 600px) {
  .prod-thumb, .prod-thumb-empty { width: 76px; height: 76px; margin: 10px; }
  .prod-order-no { font-size: 17px; }
  .prod-item-img { width: 110px !important; height: 110px !important; }
}

/* Archived / Tamamlanan sipariş kartı */
.archived-card { background: #f4faf4; border: 1px solid #b2dfdb; border-left: 5px solid #2e7d32; border-radius: 8px; padding: 0; display: flex; align-items: stretch; box-shadow: 0 1px 4px rgba(46,125,50,.08); overflow: hidden; }
.archived-date-col { background: #2e7d32; color: white; min-width: 72px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 14px 10px; gap: 2px; flex-shrink: 0; }
.archived-date-label { font-size: 11px; opacity: 0.85; letter-spacing: 0.03em; margin-bottom: 4px; }
.archived-date-day { font-size: 32px; font-weight: 800; line-height: 1; }
.archived-date-month { font-size: 12px; font-weight: 600; opacity: 0.9; text-transform: uppercase; }
.archived-date-time { font-size: 11px; opacity: 0.75; margin-top: 2px; }
.archived-thumb-col { display: flex; align-items: center; padding: 10px 0 10px 12px; flex-shrink: 0; }
.archived-thumb { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; border: 2px solid #b2dfdb; }
.archived-body { flex: 1; padding: 14px 16px; min-width: 0; }
.archived-header { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.archived-order-no { font-size: 22px; font-weight: 900; color: #1b5e20; background: #e8f5e9; padding: 2px 12px; border-radius: 8px; border: 2px solid #a5d6a7; letter-spacing: 0.02em; }
.archived-customer { font-size: 14px; color: #444; }
.archived-item { margin-bottom: 6px; }
.archived-item-title { font-size: 13px; color: #555; font-style: italic; }
.archived-tag { font-size: 13px; font-weight: 700; padding: 3px 10px; border-radius: 6px; }
.archived-tag-dark { background: #2c1a0e; color: white; }
.archived-tag-red { background: #8b1a2f; color: white; }
.archived-tag-light { background: #e8f5e9; color: #2e7d32; font-weight: 500; font-style: normal; }
.archived-actions { display: flex; flex-direction: column; gap: 6px; align-self: center; margin-left: 8px; }

@media (max-width: 600px) {
  /* archived-card: thumbnail gizle, butonlar alta in */
  .archived-date-col { min-width: 54px; padding: 10px 6px; }
  .archived-date-day { font-size: 22px; }
  .archived-date-label { font-size: 10px; }
  .archived-thumb-col { display: none; }
  .archived-card { flex-wrap: wrap; }
  .archived-body { padding: 10px 12px; width: 0; }
  .archived-actions { flex-direction: row; flex-wrap: wrap; margin-left: 0;
    align-self: auto; width: 100%; padding: 0 10px 10px; gap: 6px; }
  .archived-order-no { font-size: 16px; padding: 2px 8px; }
  .archived-customer { font-size: 13px; }
  .archived-item-title { font-size: 12px; }

  /* prod-card: fotoğraf şeridini küçült, badge küçült */
  .prod-card-photo { width: 90px; }
  .prod-card-badge { font-size: 16px; padding: 5px 12px; border-radius: 0 0 0 10px; }
  .prod-body { padding: 10px 10px 8px; }
  .prod-status-form { flex-wrap: wrap; }
  .prod-select { font-size: 13px; }
  .prod-note-input { min-width: 80px; font-size: 13px; }

  /* Section headings */
  .section-heading { font-size: 17px; }

  /* Header nav: sıkıştır */
  nav { gap: 8px; }
  .nav-link { font-size: 12px; }
  .nav-user { display: none; }
  header { padding: 12px 14px; }
  .header-brand-text { font-size: 13px; }
  .header-logo { height: 28px; }
}

/* Marka / Logo */
.header-brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.header-brand-text { font-size: 17px; font-weight: 600; color: white; }
.header-logo { height: 40px; width: auto; }
.login-logo { display: block; margin: 0 auto 20px; max-width: 160px; height: auto; }

/* ─── Worker Panel Stilleri ─── */

/* Liste kartı: thumbnail solda, bilgi sağda */
.worker-card {
  background: #fffdf9;
  border: 1px solid #e8ddd4;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 2px 8px rgba(44,26,14,.07);
  text-decoration: none;
  color: inherit;
  display: flex;
}
.worker-card.status-received        { border: 3px solid #1565c0; background: #dbeafe; }
.worker-card.status-in_production   { border: 3px solid #16a34a; background: #dcfce7; }
.worker-card.status-production_done { border: 3px solid #7c3aed; background: #ede9fe; }
.worker-card.status-pending         { border: 2px solid #ccc; }

.worker-thumb {
  width: 90px;
  height: 90px;
  object-fit: cover;
  flex-shrink: 0;
  align-self: center;
  margin: 12px;
  border-radius: 8px;
  border: 1px solid #e0d4c8;
}
.worker-thumb-empty {
  width: 90px;
  height: 90px;
  background: #f0ebe4;
  flex-shrink: 0;
  align-self: center;
  margin: 12px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: #c9a882;
}
.worker-body {
  flex: 1;
  padding: 12px 14px 12px 4px;
  min-width: 0;
}
.worker-header {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}
.worker-customer {
  font-size: 16px;
  font-weight: 700;
  color: #2c1a0e;
}
.worker-orderno {
  font-size: 14px;
  font-weight: 900;
  color: #fff;
  background: #e07b2a;
  border-radius: 6px;
  padding: 2px 9px;
  letter-spacing: 0.02em;
  white-space: nowrap;
}
.worker-item {
  font-size: 13px;
  color: #555;
  margin-bottom: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.worker-pers {
  background: #fff8e1;
  border: 1.5px solid #ffcc02;
  border-radius: 6px;
  padding: 4px 10px;
  font-size: 14px;
  font-weight: 700;
  color: #5a3e00;
  margin: 4px 0;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.worker-meta {
  font-size: 12px;
  color: #aaa;
  margin-top: 4px;
}

/* Detay sayfası — tam genişlik ürün görseli */
.worker-detail-img {
  width: 100%;
  max-height: 260px;
  object-fit: cover;
  border-radius: 10px;
  margin-bottom: 16px;
}

/* Kişiselleştirme kutusu (detay) */
.worker-pers-box {
  background: #fff8e1;
  border: 2px solid #ffcc02;
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 16px;
  font-weight: 700;
  color: #5a3e00;
  margin: 12px 0;
  user-select: all;
}
.worker-pers-box-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  color: #aaa;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

/* Aksiyon butonları */
.btn-worker-primary {
  display: block;
  width: 100%;
  padding: 16px;
  font-size: 17px;
  font-weight: 700;
  background: #f47a2b;
  color: white;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  text-align: center;
  margin-bottom: 10px;
}
.btn-worker-primary:hover { background: #d4651b; }
.btn-worker-primary:disabled,
.btn-worker-primary[disabled] {
  background: #e0d4c8;
  color: #aaa;
  cursor: not-allowed;
}

.btn-worker-secondary {
  display: block;
  width: 100%;
  padding: 13px;
  font-size: 15px;
  font-weight: 600;
  background: #f5ede4;
  color: #2c1a0e;
  border: 2px solid #e0d4c8;
  border-radius: 10px;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  margin-bottom: 10px;
}
.btn-worker-secondary:hover { background: #ece0d5; }

.worker-disabled-msg {
  background: #fdecea;
  color: #b71c1c;
  border-radius: 8px;
  padding: 10px 14px;
  font-size: 14px;
  margin-bottom: 10px;
}

/* Kargo fotoğrafı upload alanı */
.worker-photo-upload {
  border: 2px dashed #c9a882;
  border-radius: 10px;
  padding: 20px;
  text-align: center;
  background: #fffdf9;
  margin-bottom: 12px;
}
.worker-photo-upload p {
  color: #888;
  font-size: 14px;
  margin-bottom: 12px;
}
.worker-photo-preview {
  width: 100%;
  max-height: 200px;
  object-fit: cover;
  border-radius: 8px;
  margin-top: 10px;
  display: none;
}

@media (max-width: 600px) {
  .worker-thumb, .worker-thumb-empty { width: 110px; height: 110px; margin: 10px; }
  .worker-customer { font-size: 15px; }
  .worker-order-img { width: 120px !important; height: 120px !important; }
}
