/* ============================================================
   GIORGIALEONE.COM — admin.css
   Backend interface
   ============================================================ */

:root {
  --adm-bg:       #f5f6fa;
  --adm-white:    #ffffff;
  --adm-dark:     #1a1a2e;
  --adm-primary:  #c9a96e;
  --adm-primary-h:#b8915a;
  --adm-danger:   #e53e3e;
  --adm-success:  #38a169;
  --adm-info:     #3182ce;
  --adm-rose:     #b8766b;
  --adm-border:   #e2e8f0;
  --adm-text:     #2d3748;
  --adm-muted:    #718096;
  --adm-sidebar-w: 240px;
  --adm-topbar-h:  60px;
  --adm-radius:    8px;
  --adm-shadow:    0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);

  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-body:    'Inter', system-ui, sans-serif;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0 }
html { scroll-behavior: smooth }
body {
  font-family: var(--font-body);
  font-size: 14px;
  color: var(--adm-text);
  background: var(--adm-bg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none }
img { max-width: 100%; display: block }
button { cursor: pointer; border: none; background: none; font: inherit }
input, textarea, select { font: inherit }

/* ── Login ──────────────────────────────────────────────── */
.login-body {
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--adm-dark);
  padding: 1.5rem;
}
.login-wrap {
  background: var(--adm-white);
  border-radius: var(--adm-radius);
  padding: 2.5rem;
  width: 100%;
  max-width: 380px;
  box-shadow: 0 20px 60px rgba(0,0,0,.4);
}
.login-brand {
  text-align: center;
  margin-bottom: 2rem;
}
.login-brand__name {
  display: block;
  font-family: var(--font-display);
  font-style: italic;
  font-size: 2rem;
  font-weight: 300;
  color: var(--adm-dark);
  line-height: 1;
}
.login-brand__surname {
  display: block;
  font-size: .65rem;
  font-weight: 700;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: var(--adm-primary);
  margin-top: 4px;
}
.login-brand__sub {
  display: block;
  font-size: .75rem;
  color: var(--adm-muted);
  margin-top: .5rem;
}
.login-form { display: grid; gap: 1rem }
.login-back  { text-align: center; margin-top: 1.25rem; font-size: .8rem; color: var(--adm-muted) }
.login-back a:hover { color: var(--adm-primary) }

/* ── Layout ─────────────────────────────────────────────── */
.admin-body { display: flex; min-height: 100svh }

/* Sidebar */
.admin-sidebar {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--adm-sidebar-w);
  background: var(--adm-dark);
  display: flex;
  flex-direction: column;
  z-index: 200;
  transform: translateX(-100%);
  transition: transform .3s cubic-bezier(.16,1,.3,1);
  overflow-y: auto;
}
.admin-sidebar.open { transform: none }
@media (min-width: 900px) { .admin-sidebar { transform: none } }

.sidebar-brand {
  padding: 1.5rem 1.25rem 1rem;
  border-bottom: 1px solid rgba(255,255,255,.08);
}
.sidebar-brand__link { display: flex; flex-direction: column; gap: 2px }
.sidebar-brand__name {
  font-family: var(--font-display);
  font-style: italic;
  font-size: 1.3rem;
  font-weight: 300;
  color: #fff;
  line-height: 1;
}
.sidebar-brand__surname {
  font-size: .55rem;
  font-weight: 700;
  letter-spacing: .25em;
  text-transform: uppercase;
  color: var(--adm-primary);
}

.sidebar-nav {
  flex: 1;
  padding: .75rem 0;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
.sidebar-nav__item {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .6rem 1.25rem;
  color: rgba(255,255,255,.65);
  font-size: .8rem;
  font-weight: 500;
  transition: background .15s, color .15s;
  border-radius: 0;
}
.sidebar-nav__item:hover { background: rgba(255,255,255,.07); color: #fff }
.sidebar-nav__item.active {
  background: var(--adm-primary);
  color: var(--adm-dark);
  font-weight: 600;
}
.sidebar-nav__icon { font-size: 1rem; width: 20px; text-align: center; flex-shrink: 0 }
.sidebar-nav__label { white-space: nowrap }

.sidebar-footer {
  padding: 1rem 1.25rem;
  border-top: 1px solid rgba(255,255,255,.08);
  display: flex;
  flex-direction: column;
  gap: .6rem;
}
.sidebar-footer__link,
.sidebar-footer__logout {
  font-size: .75rem;
  color: rgba(255,255,255,.5);
  transition: color .2s;
}
.sidebar-footer__link:hover { color: var(--adm-primary) }
.sidebar-footer__divider {
  height: 1px;
  background: rgba(255,255,255,.1);
  margin: .1rem 0;
}
.sidebar-footer__logout {
  display: flex;
  align-items: center;
  gap: .4rem;
  color: rgba(220,80,80,.75);
  font-weight: 600;
  letter-spacing: .02em;
}
.sidebar-footer__logout:hover { color: var(--adm-danger) }

/* Main area */
.admin-main {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100svh;
  margin-left: 0;
  transition: margin-left .3s;
}
.admin-topbar {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--adm-topbar-h);
  background: var(--adm-white);
  border-bottom: 1px solid var(--adm-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-inline: 1.5rem;
  box-shadow: var(--adm-shadow);
}
.admin-topbar__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--adm-dark);
}
.admin-topbar__user {
  font-size: .8rem;
  color: var(--adm-muted);
}
.admin-content {
  flex: 1;
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  max-width: 1100px;
  width: 100%;
}

/* Sidebar toggle (mobile) — ciak */
.sidebar-toggle {
  position: fixed;
  top: .9rem; left: .9rem;
  z-index: 300;
  width: 42px; height: 42px;
  border-radius: 12px;
  background: var(--adm-dark);
  border: 1px solid rgba(201,164,106,.25);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 8px rgba(0,0,0,.35);
  transition: left .3s cubic-bezier(.16,1,.3,1), background .2s;
}
.sidebar-toggle:hover { background: #252540; border-color: rgba(201,164,106,.5) }
.sidebar-toggle:focus-visible { outline: 2px solid var(--adm-primary); outline-offset: 3px }

/* Quando la sidebar è aperta: il bottone scivola a destra della sidebar */
.sidebar-toggle.sidebar-is-open { left: calc(var(--adm-sidebar-w) + .75rem) }

/* SVG ciak admin */
.adm-clapper-svg { display: block; width: 28px; height: 28px }

.ac-body {
  fill: rgba(255,255,255,.06);
  stroke: rgba(255,255,255,.65);
  stroke-width: 1.5;
}
.ac-line {
  stroke: rgba(255,255,255,.55);
  stroke-width: 1.3;
  stroke-linecap: round;
  transition: opacity .3s;
}
.ac-arm {
  transform-box: fill-box;
  transform-origin: 0% 50%;
  transition: transform 320ms cubic-bezier(.34,1.2,.64,1);
}
.ac-arm-fill   { fill: var(--adm-primary) }
.ac-stripe     { stroke: rgba(26,26,46,.55); stroke-width: 3.5 }
.ac-arm-outline { fill: none; stroke: rgba(201,164,106,.3); stroke-width: .8 }

/* Hover: anticipo movimento */
.sidebar-toggle:hover:not([aria-expanded="true"]) .ac-arm { transform: rotate(-10deg) }

/* Stato aperto: braccio clap */
.sidebar-toggle[aria-expanded="true"] .ac-arm { transform: rotate(-40deg) }
.sidebar-toggle[aria-expanded="true"] .ac-line { opacity: .35 }

/* ── Admin card ─────────────────────────────────────────── */
.admin-card {
  background: var(--adm-white);
  border-radius: var(--adm-radius);
  box-shadow: var(--adm-shadow);
  padding: 1.5rem;
}
.admin-card__header {
  margin-bottom: 1.25rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--adm-border);
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .5rem;
}
.admin-card__title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--adm-dark);
}
.admin-card__desc  { font-size: .8rem; color: var(--adm-muted); margin-top: .2rem }
.admin-card__action { font-size: .75rem; color: var(--adm-primary); font-weight: 500 }
.admin-card__action:hover { text-decoration: underline }
.admin-empty { color: var(--adm-muted); font-size: .85rem; text-align: center; padding: 1.5rem }
.admin-intro { color: var(--adm-muted); font-size: .85rem; margin-bottom: .25rem }

/* ── Alerts ─────────────────────────────────────────────── */
.admin-alert {
  padding: .75rem 1rem;
  border-radius: var(--adm-radius);
  font-size: .85rem;
  font-weight: 500;
  transition: opacity .4s;
}
.admin-alert--success { background: #f0fff4; color: var(--adm-success); border: 1px solid #c6f6d5 }
.admin-alert--error   { background: #fff5f5; color: var(--adm-danger);  border: 1px solid #fed7d7 }
.admin-alert--info    { background: #ebf8ff; color: var(--adm-info);    border: 1px solid #bee3f8 }
.admin-alert--warning { background: #fffbeb; color: #92400e;            border: 1px solid #fde68a }
.admin-alert--warning a { color: #92400e; font-weight: 600 }

/* ── Forms ──────────────────────────────────────────────── */
.form-group   { display: grid; gap: .4rem }
.form-row-2   { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(200px,1fr)) }
.form-row-3   { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(160px,1fr)) }
.form-label {
  font-size: .7rem;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--adm-muted);
  display: flex;
  align-items: center;
  gap: .5rem;
}
.form-label__count { font-weight: 400; text-transform: none; letter-spacing: 0 }
.form-input {
  width: 100%;
  padding: .6rem .85rem;
  border: 1.5px solid var(--adm-border);
  border-radius: var(--adm-radius);
  background: var(--adm-white);
  color: var(--adm-text);
  font-size: .875rem;
  transition: border-color .2s, box-shadow .2s;
}
.form-input:focus {
  outline: none;
  border-color: var(--adm-primary);
  box-shadow: 0 0 0 3px rgba(201,169,110,.15);
}
.form-input--inline { padding: .4rem .6rem; font-size: .8rem }
.form-textarea   { resize: vertical; min-height: 100px }
.form-textarea--sm { min-height: 70px }
.form-input-file { font-size: .8rem; color: var(--adm-muted); padding: .4rem 0 }
.form-hint   { font-size: .72rem; color: var(--adm-muted) }
.form-actions {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding-top: 1.25rem;
  flex-wrap: wrap;
}

/* ── Buttons ────────────────────────────────────────────── */
.btn-admin {
  display: inline-flex;
  align-items: center;
  gap: .4rem;
  padding: .55rem 1.25rem;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .06em;
  border-radius: var(--adm-radius);
  border: 1.5px solid transparent;
  transition: all .2s;
  white-space: nowrap;
}
.btn-admin--primary   { background: var(--adm-primary); color: var(--adm-dark); border-color: var(--adm-primary) }
.btn-admin--primary:hover { background: var(--adm-primary-h); border-color: var(--adm-primary-h) }
.btn-admin--secondary { background: var(--adm-dark); color: #fff; border-color: var(--adm-dark) }
.btn-admin--secondary:hover { opacity: .85 }
.btn-admin--ghost     { background: transparent; color: var(--adm-muted); border-color: var(--adm-border) }
.btn-admin--ghost:hover { border-color: var(--adm-muted); color: var(--adm-text) }
.btn-admin--danger    { background: var(--adm-danger); color: #fff; border-color: var(--adm-danger) }
.btn-admin--danger:hover { opacity: .85 }
.btn-admin--sm        { padding: .3rem .65rem; font-size: .72rem }
.btn-admin--full      { width: 100%; justify-content: center }

/* ── Dashboard ──────────────────────────────────────────── */
.dashboard-stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1rem;
}
.stat-card {
  background: var(--adm-white);
  border-radius: var(--adm-radius);
  box-shadow: var(--adm-shadow);
  padding: 1.25rem;
  text-align: center;
  transition: transform .2s, box-shadow .2s;
  border-top: 3px solid var(--adm-primary);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.12) }
.stat-card__value { font-size: 2rem; font-weight: 700; color: var(--adm-dark) }
.stat-card__label { font-size: .75rem; color: var(--adm-muted); margin-top: .2rem }

.dashboard-grid { display: grid; gap: 1.5rem }
.quick-links     { display: grid; grid-template-columns: repeat(2, 1fr); gap: .75rem }
.quick-link {
  display: flex;
  align-items: center;
  gap: .6rem;
  padding: .75rem;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  font-size: .8rem;
  font-weight: 500;
  color: var(--adm-text);
  transition: background .15s, color .15s;
}
.quick-link:hover { background: var(--adm-primary); color: var(--adm-dark) }
.quick-link__icon { font-size: 1.1rem }

.recent-list { display: grid; gap: .5rem }
.recent-item {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .5rem .75rem;
  border-radius: var(--adm-radius);
  transition: background .15s;
}
.recent-item:hover { background: var(--adm-bg) }
.recent-item__cat {
  font-size: .65rem;
  font-weight: 600;
  padding: .2rem .5rem;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: .08em;
  flex-shrink: 0;
}
.recent-item__cat--attrice       { background: rgba(201,169,110,.15); color: #b07c3a }
.recent-item__cat--presentatrice { background: rgba(184,118,107,.15); color: var(--adm-rose) }
.recent-item__cat--modella       { background: rgba(26,26,26,.08); color: var(--adm-dark) }
.recent-item__title { flex: 1; font-size: .83rem; font-weight: 500 }
.recent-item__year  { font-size: .75rem; color: var(--adm-muted) }

.admin-info-bar {
  display: flex;
  align-items: center;
  gap: .5rem;
  font-size: .8rem;
  color: var(--adm-muted);
  padding: .75rem 1rem;
  background: var(--adm-white);
  border-radius: var(--adm-radius);
  box-shadow: var(--adm-shadow);
}
.admin-info-bar a { color: var(--adm-primary); font-weight: 500 }
.admin-info-bar a:hover { text-decoration: underline }

/* ── Table ──────────────────────────────────────────────── */
.data-table-wrap { overflow-x: auto; margin-bottom: 1rem }
.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .83rem;
}
.admin-table th {
  text-align: left;
  font-size: .68rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: var(--adm-muted);
  padding: .6rem .75rem;
  border-bottom: 2px solid var(--adm-border);
  white-space: nowrap;
}
.admin-table td {
  padding: .65rem .75rem;
  border-bottom: 1px solid var(--adm-border);
  vertical-align: middle;
}
.admin-table tbody tr:hover { background: var(--adm-bg) }
.admin-table .col-vis { width: 80px; text-align: center }
.admin-table .col-act { width: 60px; text-align: center }

.table-label { display: block; font-weight: 500 }
.table-key   { display: block; font-size: .72rem; color: var(--adm-muted) }

/* ── Toggle ─────────────────────────────────────────────── */
.toggle { position: relative; display: inline-block; width: 40px; height: 22px }
.toggle input { opacity: 0; width: 0; height: 0; position: absolute }
.toggle__slider {
  position: absolute;
  inset: 0;
  background: var(--adm-border);
  border-radius: 99px;
  cursor: pointer;
  transition: background .2s;
}
.toggle__slider::before {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  left: 3px; top: 3px;
  background: #fff;
  border-radius: 50%;
  transition: transform .2s;
  box-shadow: 0 1px 3px rgba(0,0,0,.2);
}
.toggle input:checked + .toggle__slider { background: var(--adm-primary) }
.toggle input:checked + .toggle__slider::before { transform: translateX(18px) }

.toggle-list { display: grid; gap: .5rem }
.toggle-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .75rem 1rem;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
}
.toggle-row__label { font-size: .85rem; font-weight: 500 }

/* ── Badges ─────────────────────────────────────────────── */
.badge {
  display: inline-block;
  font-size: .65rem;
  font-weight: 600;
  padding: .2rem .5rem;
  border-radius: 99px;
  text-transform: uppercase;
  letter-spacing: .06em;
}
.badge--telefono { background: #ebf8ff; color: #2b6cb0 }
.badge--email    { background: #f0fff4; color: #276749 }
.badge--whatsapp { background: #f0fff4; color: #276749 }
.badge--social   { background: #faf5ff; color: #553c9a }
.badge--altro    { background: var(--adm-bg); color: var(--adm-muted) }

/* ── Images ─────────────────────────────────────────────── */
.current-img-wrap { margin-bottom: .75rem }
.current-img {
  width: 120px;
  height: 80px;
  object-fit: cover;
  border-radius: var(--adm-radius);
  border: 2px solid var(--adm-border);
}
.current-img__label { font-size: .72rem; color: var(--adm-muted); display: block; margin-top: .25rem }

/* ── Toolbar ────────────────────────────────────────────── */
.admin-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: .75rem;
}
.filter-tabs--admin { margin-bottom: 0 }
.filter-tabs--admin .filter-tab {
  padding: .4rem .9rem;
  font-size: .7rem;
}
.table-count {
  font-size: .75rem;
  color: var(--adm-muted);
  margin-top: .75rem;
}

/* ── Badges esperienze ──────────────────────────────────── */
.badge--attrice       { background: rgba(201,169,110,.15); color: #8a6020 }
.badge--presentatrice { background: rgba(184,118,107,.15); color: #7a3d36 }
.badge--modella       { background: rgba(26,26,50,.08);    color: #333 }

/* ── Dot status ─────────────────────────────────────────── */
.dot { font-size: .85rem }
.dot--green { color: #38a169 }
.dot--gold  { color: var(--adm-primary) }
.dot--gray  { color: #ccc }

/* ── Row states ─────────────────────────────────────────── */
.row--hidden td { opacity: .45 }
.year-cell { font-size: .8rem; white-space: nowrap }
.text-muted { color: var(--adm-muted) }
.action-btns { display: flex; gap: .4rem; align-items: center }

/* ── Toggle inline ──────────────────────────────────────── */
.toggle-row--inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: .75rem 1rem;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  cursor: pointer;
}
.toggle--sm { width: 34px; height: 18px }
.toggle--sm .toggle__slider::before { width: 12px; height: 12px; left: 3px; top: 3px }
.toggle--sm input:checked + .toggle__slider::before { transform: translateX(16px) }

/* ── Drag & drop ────────────────────────────────────────── */
.drag-handle {
  cursor: grab;
  color: var(--adm-muted);
  font-size: 1rem;
  user-select: none;
  padding: 0 .25rem;
  display: inline-block;
}
.drag-handle:active { cursor: grabbing }
.sortable-row.dragging { opacity: .4; background: var(--adm-bg) }

/* ── Skills admin list ──────────────────────────────────── */
.skills-admin-list { list-style: none; display: grid; gap: .5rem; margin-bottom: 1rem }
.skills-admin-item {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .5rem .75rem;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  border: 1px solid var(--adm-border);
}
.skills-admin-input { flex: 1 }

/* ── Image wide ─────────────────────────────────────────── */
.current-img--wide { width: 200px; height: 120px }

/* ── Upload zone ────────────────────────────────────────── */
.upload-zone {
  border: 2px dashed var(--adm-border);
  border-radius: var(--adm-radius);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: border-color .2s, background .2s;
}
.upload-zone:hover,
.upload-zone.dragover { border-color: var(--adm-primary); background: rgba(201,169,110,.05) }
.upload-zone__icon  { font-size: 2rem; margin-bottom: .5rem }
.upload-zone__text  { font-size: .9rem; color: var(--adm-muted) }
.upload-zone__browse {
  color: var(--adm-primary);
  font-weight: 600;
  cursor: pointer;
  text-decoration: underline;
}
.upload-zone__hint  { font-size: .75rem; color: var(--adm-muted); margin-top: .25rem }
.upload-preview {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem;
  margin-top: 1rem;
}
.upload-thumb {
  width: 64px; height: 64px;
  object-fit: cover;
  border-radius: var(--adm-radius);
  border: 2px solid var(--adm-border);
}
.upload-more {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 64px; height: 64px;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  font-size: .8rem;
  color: var(--adm-muted);
  font-weight: 600;
}
.upload-count { font-size: .8rem; color: var(--adm-muted) }
.admin-card-toolbar { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap }

/* ── Photo grid ─────────────────────────────────────────── */
.gallery-toolbar {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
  padding-bottom: .75rem;
  border-bottom: 1px solid var(--adm-border);
}
.gallery-select-all { display: flex; align-items: center; gap: .4rem; font-size: .8rem; cursor: pointer }
.gallery-count      { font-size: .8rem; color: var(--adm-muted) }

.admin-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: .75rem;
}
.photo-card {
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  border: 1px solid var(--adm-border);
  overflow: hidden;
  transition: box-shadow .2s, transform .2s;
  cursor: grab;
}
.photo-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.1) }
.photo-card.dragging { opacity: .4; cursor: grabbing }
.photo-card--hidden { opacity: .55 }
.photo-card__check  {
  position: absolute;
  top: .4rem; left: .4rem;
  z-index: 2;
}
.photo-card__img-wrap {
  position: relative;
  aspect-ratio: 4/5;
  overflow: hidden;
}
.photo-card__img-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  display: block;
  transition: transform .3s;
}
.photo-card:hover .photo-card__img-wrap img { transform: scale(1.04) }
.photo-card__badge,
.photo-card__hidden-badge {
  position: absolute;
  top: .4rem; right: .4rem;
  background: rgba(0,0,0,.65);
  color: #fff;
  font-size: .65rem;
  padding: .15rem .35rem;
  border-radius: 99px;
}
.photo-card__badge { color: var(--adm-primary) }
.photo-card__info {
  padding: .4rem .5rem .2rem;
  display: flex;
  flex-direction: column;
  gap: .1rem;
}
.photo-card__cat { font-size: .65rem; font-weight: 600; color: var(--adm-primary); text-transform: uppercase; letter-spacing: .06em }
.photo-card__alt { font-size: .72rem; color: var(--adm-muted) }
.photo-card__actions {
  display: flex;
  gap: .3rem;
  padding: .4rem .5rem .5rem;
}

/* ── Modal ──────────────────────────────────────────────── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-overlay:not(:target) { display: none }
.modal {
  background: var(--adm-white);
  border-radius: var(--adm-radius);
  width: 100%;
  max-width: 560px;
  max-height: 90svh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.3);
}
.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--adm-border);
}
.modal__title { font-size: 1rem; font-weight: 600 }
.modal__close { font-size: 1.2rem; color: var(--adm-muted); transition: color .2s }
.modal__close:hover { color: var(--adm-danger) }
.modal__body  { padding: 1.25rem }
.modal-photo-wrap { margin-bottom: 1rem }
.modal-photo  { width: 100%; max-height: 220px; object-fit: contain; border-radius: var(--adm-radius) }

/* ── Video source tabs ──────────────────────────────────── */
.video-source-tabs {
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  margin-bottom: .75rem;
}
.video-source-tab {
  cursor: pointer;
}
.video-source-tab input { display: none }
.video-source-tab span {
  display: block;
  padding: .45rem 1rem;
  border: 1.5px solid var(--adm-border);
  border-radius: var(--adm-radius);
  font-size: .78rem;
  font-weight: 500;
  color: var(--adm-muted);
  transition: all .15s;
}
.video-source-tab input:checked + span {
  border-color: var(--adm-primary);
  background: rgba(201,169,110,.1);
  color: var(--adm-text);
}

/* ── Video admin grid ───────────────────────────────────── */
.video-admin-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px,1fr));
  gap: 1rem;
}
.video-admin-card {
  background: var(--adm-bg);
  border: 1px solid var(--adm-border);
  border-radius: var(--adm-radius);
  overflow: hidden;
  transition: box-shadow .2s;
}
.video-admin-card:hover { box-shadow: 0 4px 12px rgba(0,0,0,.1) }
.video-admin-card--hidden { opacity: .55 }
.video-admin-thumb {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--adm-dark);
}
.video-admin-thumb img { width: 100%; height: 100%; object-fit: cover }
.video-admin-placeholder {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  font-size: 2rem;
  color: rgba(255,255,255,.3);
}
.video-admin-type,
.video-admin-home-badge,
.video-admin-hidden-badge {
  position: absolute;
  bottom: .4rem; left: .4rem;
  font-size: .65rem; font-weight: 600;
  padding: .15rem .4rem;
  border-radius: 99px;
  background: rgba(0,0,0,.7); color: #fff;
}
.video-admin-home-badge  { left: auto; right: .4rem; bottom: .4rem }
.video-admin-hidden-badge { top: .4rem; left: .4rem; bottom: auto; background: rgba(229,62,62,.8) }
.video-admin-body    { padding: .75rem }
.video-admin-title   { font-size: .9rem; font-weight: 600; margin-bottom: .3rem }
.video-admin-meta    { display: flex; align-items: center; gap: .5rem; margin-bottom: .25rem }
.video-admin-desc    { font-size: .78rem; color: var(--adm-muted) }
.video-admin-link    { font-size: .75rem; color: var(--adm-primary) }
.video-admin-actions {
  display: flex; gap: .4rem;
  padding: .5rem .75rem .75rem;
}
.badge--upload  { background: #fef3c7; color: #92400e }
.badge--youtube { background: #fee2e2; color: #991b1b }
.badge--vimeo   { background: #e0e7ff; color: #3730a3 }

/* ── Hero preview ───────────────────────────────────────── */
.hero-preview-card .admin-card__header { margin-bottom: .75rem }
.hero-preview {
  position: relative;
  border-radius: var(--adm-radius);
  overflow: hidden;
  aspect-ratio: 16/7;
  background: var(--adm-dark);
  max-height: 280px;
}
.hero-preview__video,
.hero-preview__poster {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
}
.hero-preview__placeholder {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.3);
  font-size: .9rem;
}
.hero-preview__overlay {
  position: absolute; inset: 0;
  background: rgba(0,0,0,.55);
}
.hero-preview__text {
  position: absolute;
  bottom: 1rem; left: 1.25rem;
  z-index: 2;
}
.hero-preview__eyebrow { font-size: .65rem; letter-spacing: .15em; color: var(--adm-primary); text-transform: uppercase; margin-bottom: .25rem }
.hero-preview__title   { font-size: clamp(1.2rem, 4vw, 2rem); color: #fff; font-family: var(--font-display); font-weight: 300 }
.hero-preview__claim   { font-size: .8rem; color: rgba(255,255,255,.75); max-width: 40ch }

/* ── Range input ────────────────────────────────────────── */
.range-input {
  width: 100%;
  accent-color: var(--adm-primary);
  height: 4px;
  border-radius: 2px;
  cursor: pointer;
}

/* ── Current file ───────────────────────────────────────── */
.current-file-info {
  display: flex;
  align-items: center;
  gap: .75rem;
  padding: .75rem;
  background: var(--adm-bg);
  border-radius: var(--adm-radius);
  margin-bottom: .75rem;
  font-size: .85rem;
}
.current-file-icon { font-size: 1.3rem }
.current-file-info a { color: var(--adm-primary); font-weight: 500 }

/* ── Responsive ─────────────────────────────────────────── */
@media (max-width: 899px) {
  /* sposta topbar a destra del burger (40px bottone + 1rem left + 0.75rem gap) */
  .admin-topbar { padding-left: calc(40px + 1.75rem) }
}

@media (min-width: 900px) {
  .sidebar-toggle { display: none }
  .admin-sidebar  { transform: none }
  .admin-main     { margin-left: var(--adm-sidebar-w) }
  .dashboard-stats { grid-template-columns: repeat(4, 1fr) }
  .dashboard-grid  { grid-template-columns: 1fr 1fr }
  .quick-links     { grid-template-columns: repeat(3, 1fr) }
}

/* ═══════════════════════════════════════════════════════
   CASTING TRACKER
   ═══════════════════════════════════════════════════════ */

/* Toolbar lista */
.casting-toolbar {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: 1.25rem;
}
.casting-filter-tabs {
  display: flex;
  gap: .4rem;
  flex-wrap: wrap;
}

/* Card lista */
.casting-list { display: flex; flex-direction: column; gap: 1rem; }

.casting-card {
  background: var(--admin-card);
  border: 1px solid var(--admin-line);
  border-radius: 10px;
  padding: 1rem 1.1rem;
  transition: border-color .2s, box-shadow .2s;
}
.casting-card--scaduta { opacity: .65; }
.casting-card--saved   { border-color: #4caf50; box-shadow: 0 0 0 3px rgba(76,175,80,.15); }

.casting-card__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .5rem;
  margin-bottom: .6rem;
  flex-wrap: wrap;
}
.casting-card__meta { display: flex; gap: .5rem; align-items: center; flex-wrap: wrap; }

.casting-tipo {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--admin-muted);
  background: var(--admin-hover);
  padding: 2px 8px;
  border-radius: 20px;
}

/* Badge stato */
.casting-badge {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 20px;
  white-space: nowrap;
}
.casting-badge--draft    { background:#3a3a3a; color:#aaa; }
.casting-badge--sent     { background:#1a3a5c; color:#7ab3f0; }
.casting-badge--wait     { background:#3a2e00; color:#f0c040; }
.casting-badge--callback { background:#2a1a4a; color:#c084fc; }
.casting-badge--ok       { background:#0f2e1a; color:#4ade80; }
.casting-badge--no       { background:#2e1414; color:#f87171; }
.casting-badge--expired  { background:#2a2a2a; color:#666; }

/* Scadenza */
.casting-scadenza {
  font-size: 12px;
  font-weight: 500;
  color: var(--admin-muted);
}
.casting-scadenza--urgente { color: #f59e0b; font-weight: 700; }
.casting-scadenza--scaduta { color: #ef4444; }

.casting-card__body { margin-bottom: .75rem; }
.casting-card__title {
  font-size: 16px;
  font-weight: 600;
  margin: 0 0 .25rem;
  color: var(--admin-text);
}
.casting-card__ruolo,
.casting-card__dove,
.casting-card__produzione {
  font-size: 13px;
  color: var(--admin-muted);
  margin: .15rem 0;
}
.casting-card__dove { display: flex; gap: .75rem; flex-wrap: wrap; }

.casting-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .75rem;
  padding-top: .75rem;
  border-top: 1px solid var(--admin-line);
  flex-wrap: wrap;
}
.casting-stato-select select {
  font-size: 13px;
  padding: 5px 8px;
  border-radius: 6px;
  border: 1px solid var(--admin-line);
  background: var(--admin-hover);
  color: var(--admin-text);
  cursor: pointer;
}
.casting-card__actions { display: flex; gap: .4rem; }

/* Form cattura AI */
.casting-divider {
  text-align: center;
  font-size: 13px;
  color: var(--admin-muted);
  margin: .75rem 0;
  position: relative;
}
.casting-divider::before,
.casting-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: calc(50% - 2.5rem);
  height: 1px;
  background: var(--admin-line);
}
.casting-divider::before { left: 0; }
.casting-divider::after  { right: 0; }

.casting-upload-label { display: block; cursor: pointer; }
.casting-upload-zone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .3rem;
  padding: 1.25rem;
  border: 2px dashed var(--admin-line);
  border-radius: 8px;
  text-align: center;
  transition: border-color .2s, background .2s;
}
.casting-upload-label:hover .casting-upload-zone,
.casting-upload-label:focus-within .casting-upload-zone {
  border-color: var(--admin-gold);
  background: rgba(184,150,126,.06);
}
.casting-upload-icon { font-size: 28px; }
.casting-upload-text { font-size: 14px; font-weight: 500; color: var(--admin-text); }
.casting-upload-hint { font-size: 12px; color: var(--admin-muted); }

/* Date card */
.casting-date-card { border-left: 3px solid var(--admin-gold); }
.casting-scadenza-highlight {
  background: rgba(184,150,126,.07);
  border-radius: 8px;
  padding: 1rem;
}
.casting-input-scadenza {
  font-size: 18px !important;
  font-weight: 600 !important;
  color: var(--admin-text) !important;
}

/* Link contatto */
.casting-contact-link {
  display: inline-block;
  margin-top: .35rem;
  font-size: 13px;
  color: var(--admin-gold);
  text-decoration: none;
}
.casting-contact-link:hover { text-decoration: underline; }

/* Evidenzia campo compilato dall'AI */
@keyframes casting-fill-flash {
  0%   { background: rgba(184,150,126,.22); }
  100% { background: transparent; }
}
.casting-field--filled { animation: casting-fill-flash 2s ease-out forwards; }


/* Alert nessuna risposta */
.admin-alert--warning {
  background: rgba(245,158,11,.12);
  border: 1px solid rgba(245,158,11,.35);
  color: #f59e0b;
  border-radius: 8px;
  padding: .9rem 1rem;
  margin-bottom: 1.25rem;
}
.admin-alert--warning a { color: inherit; }
.casting-alert-inattivi ul { list-style: disc; }
.casting-alert-inattivi li { margin: .15rem 0; font-size: 14px; }

/* Timeline aggiornamenti */
.casting-followup-card { border-left: 3px solid #7ab3f0; }
.casting-update-form { border-bottom: 1px solid var(--admin-line); padding-bottom: 1.25rem; margin-bottom: 1.25rem; }
.casting-timeline { display: flex; flex-direction: column; gap: 0; }
.casting-timeline__item {
  display: grid;
  grid-template-columns: 16px 1fr;
  gap: 0 .75rem;
  position: relative;
}
.casting-timeline__item + .casting-timeline__item { margin-top: 1rem; }
.casting-timeline__dot {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: var(--admin-gold);
  margin-top: .3rem;
  position: relative;
  z-index: 1;
  flex-shrink: 0;
}
.casting-timeline__item + .casting-timeline__item .casting-timeline__dot::before {
  content: '';
  position: absolute;
  top: -1rem;
  left: 50%;
  transform: translateX(-50%);
  width: 1px;
  height: 1rem;
  background: var(--admin-line);
}
.casting-timeline__head {
  display: flex;
  align-items: center;
  gap: .6rem;
  flex-wrap: wrap;
  margin-bottom: .35rem;
}
.casting-timeline__data { font-size: 13px; font-weight: 600; color: var(--admin-text); }
.casting-timeline__mezzo {
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 20px;
  background: var(--admin-hover);
  color: var(--admin-muted);
}
.casting-mezzo--whatsapp { background: rgba(37,211,102,.12); color: #25d366; }
.casting-mezzo--email    { background: rgba(122,179,240,.12); color: #7ab3f0; }
.casting-mezzo--telefono { background: rgba(192,132,252,.12); color: #c084fc; }
.casting-timeline__testo { font-size: 14px; color: var(--admin-text); line-height: 1.6; margin: 0 0 .4rem; }
.casting-timeline__delete {
  font-size: 11px;
  color: var(--admin-muted);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-decoration: underline;
}
.casting-timeline__delete:hover { color: #ef4444; }

/* Sezione riprese */
.casting-riprese-card { border-left: 3px solid #4ade80; }
.casting-riprese-card--collapsed { opacity: .55; }
.casting-sub-title {
  font-size: 14px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--admin-muted);
  margin: 0 0 .85rem;
}
.casting-riprese-list { display: flex; flex-direction: column; gap: .6rem; margin-top: .75rem; }
.casting-ripresa-item {
  background: var(--admin-hover);
  border-radius: 8px;
  padding: .75rem 1rem;
}
.casting-ripresa-item__head {
  display: flex;
  align-items: center;
  gap: .75rem;
  flex-wrap: wrap;
  margin-bottom: .35rem;
}
.casting-ripresa-item__data { font-size: 14px; font-weight: 600; }
.casting-ripresa-item__luogo { font-size: 13px; color: var(--admin-muted); }
.casting-ripresa-item__note { font-size: 13px; color: var(--admin-text); line-height: 1.6; margin: 0; }


/* ═══════════════════════════════════════════════════════
   CALENDARIO CASTING — Dashboard
   ═══════════════════════════════════════════════════════ */

.cal-card { padding: 1.25rem; }

.cal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.cal-title {
  font-size: 17px;
  font-weight: 600;
  margin: 0;
  text-align: center;
  flex: 1;
}
.cal-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: var(--admin-hover);
  color: var(--admin-text);
  text-decoration: none;
  font-size: 20px;
  font-weight: 300;
  line-height: 1;
  transition: background .15s;
}
.cal-nav:hover { background: var(--admin-line); }

/* Legenda */
.cal-legenda {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--admin-muted);
  margin-bottom: .85rem;
}
.cal-legenda span { display: flex; align-items: center; gap: .35rem; }

/* Griglia 7 colonne */
.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 3px;
}

/* Intestazioni giorni settimana */
.cal-dow {
  text-align: center;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--admin-muted);
  padding: .35rem 0;
}

/* Celle */
.cal-cell {
  position: relative;
  min-height: 52px;
  padding: 4px 3px 3px;
  border-radius: 6px;
  background: transparent;
  transition: background .15s;
  cursor: default;
}
.cal-cell--empty { background: transparent; }
.cal-cell--has-eventi { background: var(--admin-hover); cursor: pointer; }
.cal-cell--has-eventi:hover { background: var(--admin-line); }
.cal-cell--oggi .cal-day {
  background: var(--admin-gold);
  color: #1a1a1a;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}
.cal-day {
  font-size: 12px;
  font-weight: 500;
  color: var(--admin-text);
  display: block;
  text-align: center;
  margin-bottom: 3px;
}

/* Pallini evento */
.cal-dots {
  display: flex;
  justify-content: center;
  gap: 3px;
  flex-wrap: wrap;
}
.cal-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  display: inline-block;
  flex-shrink: 0;
}
.dot--scadenza { background: #ef4444; }
.dot--ripresa  { background: #4ade80; }
.dot--periodo  { background: #f59e0b; }

/* Tooltip al hover */
.cal-tooltip {
  display: none;
  position: absolute;
  bottom: calc(100% + 6px);
  left: 50%;
  transform: translateX(-50%);
  background: #2a2a2a;
  border: 1px solid var(--admin-line);
  border-radius: 8px;
  padding: .5rem;
  min-width: 180px;
  max-width: 240px;
  z-index: 100;
  box-shadow: 0 8px 24px rgba(0,0,0,.4);
}
.cal-cell--has-eventi:hover .cal-tooltip { display: block; }
.cal-tooltip__item {
  display: grid;
  grid-template-columns: 18px 60px 1fr;
  gap: .25rem;
  align-items: center;
  text-decoration: none;
  color: var(--admin-text);
  font-size: 12px;
  padding: .25rem .2rem;
  border-radius: 4px;
}
.cal-tooltip__item + .cal-tooltip__item { border-top: 1px solid var(--admin-line); }
.cal-tooltip__item:hover { background: var(--admin-hover); }
.cal-tooltip__tipo  { color: var(--admin-muted); font-size: 11px; }
.cal-tooltip__titolo { font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* Lista imminenti */
.cal-imminenti {
  display: flex;
  flex-direction: column;
  gap: .15rem;
}
.cal-imm-data {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--admin-muted);
  padding: .75rem 0 .25rem;
  border-top: 1px solid var(--admin-line);
  display: flex;
  align-items: center;
  gap: .5rem;
}
.cal-imminenti .cal-imm-data:first-child { border-top: none; padding-top: 0; }
.cal-imm-data--urgente { color: #f59e0b; }
.cal-imm-oggi { background: var(--admin-gold); color: #1a1a1a; font-size: 10px; padding: 1px 6px; border-radius: 20px; }
.cal-imm-fra  { background: rgba(245,158,11,.15); color: #f59e0b; font-size: 10px; padding: 1px 6px; border-radius: 20px; }

.cal-imm-item {
  display: flex;
  align-items: center;
  gap: .5rem;
  padding: .5rem .6rem;
  border-radius: 7px;
  text-decoration: none;
  color: var(--admin-text);
  transition: background .15s;
  flex-wrap: wrap;
}
.cal-imm-item:hover { background: var(--admin-hover); }
.cal-imm-icon { font-size: 15px; flex-shrink: 0; }
.cal-imm-tipo { font-size: 11px; color: var(--admin-muted); min-width: 70px; flex-shrink: 0; }
.cal-imm-titolo { font-size: 14px; font-weight: 500; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

/* Responsive calendario */
@media (max-width: 480px) {
  .cal-cell { min-height: 42px; }
  .cal-dot { width: 6px; height: 6px; }
  .cal-tooltip { display: none !important; } /* su mobile si va direttamente al casting */
  .cal-imm-tipo { display: none; }
}

