/* ── AINO MÄKINEN PHOTOGRAPHY — admin.css ── */

:root {
  --bg:      #F7F4EF;
  --bg2:     #EDE8E0;
  --bg3:     #E4DDD3;
  --fg:      #2C2825;
  --fg2:     #4A443E;
  --muted:   #8A7E74;
  --accent:  #A0855E;
  --accent2: #C4A882;
  --white:   #FDFCFA;
  --dark:    #1E1B18;
  --sidebar: #26221E;
  --green:   #3D8B5E;
  --red:     #C0444A;
  --amber:   #B07830;
  --blue:    #3A6EA8;
  --serif:   'Cormorant Garamond', Georgia, serif;
  --sans:    'Plus Jakarta Sans', Inter, sans-serif;
  --ease:    cubic-bezier(0.4,0,0.2,1);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body { font-family: var(--sans); background: var(--bg); color: var(--fg); -webkit-font-smoothing: antialiased; display: flex; min-height: 100vh; }
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: var(--sans); border: none; background: none; }
img { display: block; max-width: 100%; }

.lang-btn-admin {
  font-size: 9px; letter-spacing: 0.18em; text-transform: uppercase;
  font-weight: 600; padding: 5px 8px; border-radius: 3px;
  color: var(--muted); transition: all 0.2s; background: transparent;
  border: 1px solid transparent; cursor: pointer; font-family: var(--sans);
}
.lang-btn-admin.active, .lang-btn-admin:hover {
  color: var(--accent); background: rgba(160,133,94,0.1); border-color: rgba(160,133,94,0.3);
}

/* ── ADMIN BANNER ── */
.admin-banner {
  position: fixed; top: 0; left: 0; right: 0; z-index: 200;
  background: #1A1714; height: 38px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 20px; border-bottom: 1px solid rgba(196,168,130,0.15);
}
.admin-banner-left {
  display: flex; align-items: center; gap: 10px;
  font-size: 11px; color: rgba(247,244,239,0.45); letter-spacing: 0.04em;
}
.admin-banner .dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); flex-shrink: 0;
  animation: pulse-dot 2s ease-in-out infinite;
}
@keyframes pulse-dot {
  0%,100% { opacity:1;transform:scale(1); }
  50% { opacity:.5;transform:scale(.7); }
}
.admin-banner-right {
  display: flex; align-items: center; gap: 6px;
}
.admin-banner-right a {
  display: flex; align-items: center; gap: 5px;
  font-size: 11px; color: rgba(247,244,239,0.45);
  letter-spacing: 0.04em; text-decoration: none; padding: 4px 10px;
  border-radius: 4px; transition: all 0.2s;
}
.admin-banner-right a:hover {
  color: var(--accent2); background: rgba(196,168,130,0.1);
}
.admin-banner-right a i { font-size: 13px; }
.bsep { color: rgba(247,244,239,0.2); font-size: 11px; }
.upload-placeholder {
  width: 120px; aspect-ratio: 3/4;
  background: var(--bg2); border-radius: 6px;
  display: flex; flex-direction: column; align-items: center;
  justify-content: center; gap: 8px; cursor: pointer;
  border: 2px dashed var(--bg3); transition: all 0.2s;
}
.upload-placeholder:hover { border-color: var(--accent2); background: rgba(160,133,94,0.05); }
.upload-placeholder i { font-size: 28px; color: var(--accent2); }
.upload-placeholder span { font-size: 11px; color: var(--muted); }

/* ── SIDEBAR ── */
.sidebar {
  width: 240px; min-height: 100vh; background: var(--sidebar);
  display: flex; flex-direction: column;
  position: fixed; top: 38px; left: 0; bottom: 0; z-index: 100;
  overflow-y: auto;
}
.sidebar-logo {
  padding: 28px 24px 24px;
  border-bottom: 1px solid rgba(196,168,130,0.1);
}
.sidebar-logo-name { font-family: var(--serif); font-size: 18px; font-weight: 300; color: rgba(247,244,239,0.85); }
.sidebar-logo-sub { font-size: 9px; letter-spacing: 0.25em; text-transform: uppercase; color: var(--accent2); margin-top: 3px; }
.sidebar-nav { flex: 1; padding: 16px 0; }
.nav-item {
  display: flex; align-items: center; gap: 11px;
  padding: 11px 24px; font-size: 12px; letter-spacing: 0.04em;
  color: rgba(247,244,239,0.45); font-weight: 500;
  cursor: pointer; transition: all 0.2s; border-radius: 0;
  border-left: 2px solid transparent;
}
.nav-item:hover { color: rgba(247,244,239,0.8); background: rgba(247,244,239,0.05); }
.nav-item.active { color: var(--accent2); border-left-color: var(--accent2); background: rgba(196,168,130,0.08); }
.nav-item i { font-size: 17px; flex-shrink: 0; }
.sidebar-footer { padding: 20px 24px; border-top: 1px solid rgba(196,168,130,0.1); }
.sidebar-preview {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: rgba(247,244,239,0.4); margin-bottom: 14px;
  transition: color 0.2s;
}
.sidebar-preview:hover { color: var(--accent2); }
.sidebar-preview i { font-size: 15px; }
.sidebar-logout {
  display: flex; align-items: center; gap: 8px;
  font-size: 11px; color: rgba(247,244,239,0.3);
  transition: color 0.2s;
}
.sidebar-logout:hover { color: rgba(247,244,239,0.7); }

/* ── MAIN CONTENT ── */
.main { margin-left: 240px; flex: 1; min-height: 100vh; padding-top: 38px; }
.topbar {
  background: var(--white); border-bottom: 1px solid var(--bg3);
  padding: 0 32px; height: 64px;
  display: flex; align-items: center; justify-content: space-between;
  position: sticky; top: 38px; z-index: 50;
}
.page-title { font-size: 17px; font-weight: 600; color: var(--fg); }
.topbar-right { display: flex; align-items: center; gap: 16px; }
.admin-avatar {
  width: 36px; height: 36px; border-radius: 50%;
  background: var(--accent); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-size: 13px; font-weight: 600;
}
.content { padding: 32px; }

/* ── STATS ROW ── */
.stats-row { display: grid; grid-template-columns: repeat(4,1fr); gap: 16px; margin-bottom: 28px; }
.stat-card {
  background: var(--white); border: 1px solid var(--bg2); border-radius: 8px;
  padding: 20px 24px;
}
.stat-card-label { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.stat-card-num { font-family: var(--serif); font-size: 40px; font-weight: 300; color: var(--fg); line-height: 1; margin-bottom: 4px; }
.stat-card-sub { font-size: 12px; color: var(--muted); }
.stat-card.accent .stat-card-num { color: var(--accent); }

/* ── TABLE ── */
.table-card {
  background: var(--white); border: 1px solid var(--bg2); border-radius: 10px;
  overflow: hidden; margin-bottom: 24px;
}
.table-header {
  display: flex; align-items: center; justify-content: space-between;
  padding: 18px 24px; border-bottom: 1px solid var(--bg2);
  flex-wrap: wrap; gap: 12px;
}
.table-header-title { font-size: 14px; font-weight: 600; color: var(--fg); }
.table-controls { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.search-input {
  padding: 8px 14px; border: 1px solid var(--bg2); border-radius: 6px;
  font-size: 13px; background: var(--bg); color: var(--fg); outline: none;
  font-family: var(--sans); min-width: 200px;
}
.search-input:focus { border-color: var(--accent2); }
.filter-select {
  padding: 8px 14px; border: 1px solid var(--bg2); border-radius: 6px;
  font-size: 12px; background: var(--bg); color: var(--fg); outline: none;
  font-family: var(--sans); cursor: pointer;
}
table { width: 100%; border-collapse: collapse; }
thead tr { border-bottom: 1px solid var(--bg2); }
th {
  padding: 12px 20px; text-align: left;
  font-size: 10px; letter-spacing: 0.16em; text-transform: uppercase;
  color: var(--muted); font-weight: 600; white-space: nowrap;
}
td { padding: 15px 20px; font-size: 13px; color: var(--fg2); border-bottom: 1px solid var(--bg); }
tr:last-child td { border-bottom: none; }
tbody tr:hover { background: var(--bg); }
.td-name { font-weight: 600; color: var(--fg); font-size: 14px; }
.td-sub { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* STATUS BADGES */
.badge {
  display: inline-flex; align-items: center; gap: 5px;
  font-size: 10px; letter-spacing: 0.1em; text-transform: uppercase;
  font-weight: 600; padding: 4px 10px; border-radius: 20px;
}
.badge-new { background: rgba(58,110,168,0.12); color: var(--blue); }
.badge-pending { background: rgba(176,120,48,0.12); color: var(--amber); }
.badge-confirmed { background: rgba(61,139,94,0.12); color: var(--green); }
.badge-completed { background: rgba(160,133,94,0.15); color: var(--accent); }
.badge-cancelled { background: rgba(192,68,74,0.1); color: var(--red); }

/* ACTION BUTTONS */
.btn-action {
  padding: 5px 12px; border-radius: 5px; font-size: 11px; font-weight: 600;
  letter-spacing: 0.08em; transition: all 0.2s; border: 1px solid transparent;
}
.btn-confirm { background: rgba(61,139,94,0.12); color: var(--green); border-color: rgba(61,139,94,0.25); }
.btn-confirm:hover { background: var(--green); color: white; }
.btn-cancel-sm { background: rgba(192,68,74,0.08); color: var(--red); border-color: rgba(192,68,74,0.2); }
.btn-cancel-sm:hover { background: var(--red); color: white; }
.btn-primary-sm {
  background: var(--accent); color: var(--white);
  padding: 8px 18px; border-radius: 6px; font-size: 12px; font-weight: 600;
  transition: background 0.2s;
}
.btn-primary-sm:hover { background: var(--fg); }

/* ── GALLERY ADMIN ── */
.gallery-admin-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.gallery-admin-item { position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 6px; background: var(--bg2); }
.gallery-admin-item img { width: 100%; height: 100%; object-fit: cover; }
.gallery-admin-item .item-actions {
  position: absolute; inset: 0; background: rgba(44,40,37,0.6);
  display: flex; align-items: center; justify-content: center; gap: 8px;
  opacity: 0; transition: opacity 0.2s;
}
.gallery-admin-item:hover .item-actions { opacity: 1; }
.gallery-admin-item .item-cat-badge {
  position: absolute; bottom: 8px; left: 8px;
  background: rgba(44,40,37,0.75); color: var(--accent2);
  font-size: 9px; letter-spacing: 0.15em; text-transform: uppercase;
  padding: 3px 8px; border-radius: 3px; font-weight: 600;
}
.upload-zone {
  border: 2px dashed var(--bg3); border-radius: 8px;
  padding: 40px; text-align: center; cursor: pointer;
  transition: all 0.2s; margin-bottom: 20px;
}
.upload-zone:hover { border-color: var(--accent2); background: rgba(160,133,94,0.04); }
.upload-zone i { font-size: 32px; color: var(--accent2); margin-bottom: 12px; display: block; }
.upload-zone p { font-size: 13px; color: var(--muted); }

/* ── ABOUT EDITOR ── */
.about-editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.form-card { background: var(--white); border: 1px solid var(--bg2); border-radius: 10px; padding: 24px; }
.form-card-title { font-size: 14px; font-weight: 600; margin-bottom: 18px; color: var(--fg); border-bottom: 1px solid var(--bg2); padding-bottom: 12px; }
.admin-form-group { display: flex; flex-direction: column; gap: 6px; margin-bottom: 14px; }
.admin-label { font-size: 10px; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.admin-input, .admin-textarea, .admin-select {
  padding: 10px 14px; border: 1px solid var(--bg2); border-radius: 6px;
  font-size: 14px; background: var(--bg); color: var(--fg); outline: none;
  font-family: var(--sans); transition: border-color 0.2s; width: 100%;
}
.admin-input:focus, .admin-textarea:focus { border-color: var(--accent2); }
.admin-textarea { resize: vertical; min-height: 80px; }
.lang-tabs { display: flex; gap: 4px; margin-bottom: 14px; }
.lang-tab {
  padding: 6px 14px; font-size: 11px; letter-spacing: 0.1em;
  text-transform: uppercase; font-weight: 600; border-radius: 5px;
  color: var(--muted); transition: all 0.2s; cursor: pointer; border: 1px solid transparent;
}
.lang-tab.active { color: var(--accent); border-color: rgba(160,133,94,0.4); background: rgba(160,133,94,0.08); }
.save-bar {
  display: flex; align-items: center; justify-content: flex-end; gap: 12px;
  padding-top: 16px; border-top: 1px solid var(--bg2); margin-top: 16px;
}
.btn-save { background: var(--accent); color: var(--white); padding: 10px 24px; border-radius: 6px; font-size: 13px; font-weight: 600; transition: background 0.2s; }
.btn-save:hover { background: var(--fg); }
.btn-cancel-outline { border: 1px solid var(--bg3); color: var(--muted); padding: 10px 20px; border-radius: 6px; font-size: 13px; transition: all 0.2s; }
.btn-cancel-outline:hover { border-color: var(--fg2); color: var(--fg); }

/* ── ANALYTICS ── */
.analytics-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.chart-card { background: var(--white); border: 1px solid var(--bg2); border-radius: 10px; padding: 24px; }
.chart-title { font-size: 14px; font-weight: 600; color: var(--fg); margin-bottom: 20px; }
.bar-chart { display: flex; align-items: flex-end; gap: 8px; height: 140px; }
.bar-wrap { display: flex; flex-direction: column; align-items: center; gap: 6px; flex: 1; }
.bar { width: 100%; border-radius: 4px 4px 0 0; background: rgba(160,133,94,0.25); min-height: 4px; transition: background 0.2s; position: relative; }
.bar:hover { background: var(--accent); }
.bar-label { font-size: 10px; color: var(--muted); }
.bar-val { font-size: 11px; font-weight: 600; color: var(--fg); }
.donut-row { display: flex; flex-direction: column; gap: 10px; }
.donut-item { display: flex; align-items: center; gap: 10px; }
.donut-dot { width: 10px; height: 10px; border-radius: 50%; flex-shrink: 0; }
.donut-name { font-size: 13px; color: var(--fg2); flex: 1; }
.donut-pct { font-size: 13px; font-weight: 600; color: var(--fg); }
.donut-bar-bg { height: 4px; background: var(--bg2); border-radius: 2px; flex: 1; }
.donut-bar-fill { height: 4px; border-radius: 2px; }

/* ── SERVICES EDITOR ── */
.services-editor-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px,1fr)); gap: 16px; }
.service-editor-card { background: var(--white); border: 1px solid var(--bg2); border-radius: 10px; padding: 20px; }
.svc-num-badge { font-family: var(--serif); font-size: 32px; font-weight: 300; color: rgba(160,133,94,0.25); margin-bottom: 8px; }
.svc-editor-name { font-family: var(--serif); font-size: 18px; font-style: italic; color: var(--fg); margin-bottom: 4px; }
.svc-editor-price { font-size: 12px; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); font-weight: 600; margin-bottom: 14px; }
.svc-actions { display: flex; gap: 8px; }

/* ── REVIEWS EDITOR ── */
.reviews-editor-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px,1fr)); gap: 16px; }
.review-editor-card { background: var(--white); border: 1px solid var(--bg2); border-radius: 10px; padding: 20px; }
.review-editor-stars { display: flex; gap: 3px; margin-bottom: 12px; }
.star-sm { width: 10px; height: 10px; background: var(--accent); clip-path: polygon(50% 0%, 61% 35%, 98% 35%, 68% 57%, 79% 91%, 50% 70%, 21% 91%, 32% 57%, 2% 35%, 39% 35%); }
.review-editor-text { font-family: var(--serif); font-size: 14px; font-style: italic; color: var(--fg2); margin-bottom: 16px; line-height: 1.6; }
.review-editor-author { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; }
.review-editor-avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--accent); color: white; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 600; flex-shrink: 0; }

/* ── SETTINGS ── */
.settings-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }

/* ── MESSAGES / DETAIL MODAL ── */
.modal-overlay {
  position: fixed; inset: 0; background: rgba(44,40,37,0.5);
  z-index: 200; display: flex; align-items: center; justify-content: center;
  opacity: 0; pointer-events: none; transition: opacity 0.25s;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }
.modal {
  background: var(--white); border-radius: 12px; padding: 28px;
  width: 90%; max-width: 520px; max-height: 85vh; overflow-y: auto;
  transform: translateY(16px); transition: transform 0.3s var(--ease);
}
.modal-overlay.open .modal { transform: translateY(0); }
.modal-header { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 20px; }
.modal-title { font-size: 18px; font-weight: 600; }
.modal-close { font-size: 22px; color: var(--muted); line-height: 1; cursor: pointer; transition: color 0.2s; }
.modal-close:hover { color: var(--fg); }
.detail-row { display: flex; gap: 8px; padding: 8px 0; border-bottom: 1px solid var(--bg); }
.detail-label { font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--muted); font-weight: 600; min-width: 110px; flex-shrink: 0; padding-top: 2px; }
.detail-value { font-size: 14px; color: var(--fg2); }
.modal-message { margin-top: 16px; background: var(--bg); padding: 16px; border-radius: 6px; font-size: 14px; color: var(--fg2); line-height: 1.65; }
.modal-actions { display: flex; gap: 10px; margin-top: 20px; }

/* ── RESPONSIVE ── */
@media (max-width: 1100px) { .stats-row { grid-template-columns: repeat(2,1fr); } .analytics-grid { grid-template-columns: 1fr; } }
@media (max-width: 900px) {
  .sidebar { width: 200px; }
  .main { margin-left: 200px; }
  .about-editor-grid, .settings-grid { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .sidebar { transform: translateX(-100%); transition: transform 0.3s; }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0; }
  .stats-row { grid-template-columns: 1fr 1fr; }
  .content { padding: 16px; }
}
