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

:root {
  --ada: #b07d62;
  --salon: #6b8fa3;
  --both: #8a6fa3;
  --gold: #c9a96e;
  --dark: #1a1a1a;
  --text: #333;
  --muted: #888;
  --bg: #faf8f5;
  --white: #ffffff;
  --border: #e8e2d9;
  --radius: 10px;
  --shadow: 0 4px 20px rgba(0,0,0,.08);
}

body {
  font-family: 'Montserrat', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* ── HEADER ─────────────────────────────────────────── */
header {
  background: var(--dark);
  padding: 0 1.5rem;
  height: 60px;
  display: flex;
  align-items: center;
}
.header-inner {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.logo { display: flex; flex-direction: column; line-height: 1; flex-shrink: 0; }
.logo-ada {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 2px;
}
.logo-konsept {
  font-size: .5rem;
  color: #aaa;
  letter-spacing: 4px;
  text-transform: uppercase;
}
.header-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  font-weight: 300;
  color: #ddd;
  letter-spacing: 1px;
  flex: 1;
}
.btn-add {
  background: var(--gold);
  color: var(--dark);
  border: none;
  padding: .5rem 1rem;
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: .76rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: opacity .2s;
}
.btn-add:hover { opacity: .85; }

/* ── TOOLBAR (legend + view toggle) ─────────────────── */
.toolbar {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: .55rem 1.5rem;
  gap: 1rem;
  flex-wrap: wrap;
}
.legend {
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
}
.legend-item {
  display: flex;
  align-items: center;
  gap: .45rem;
  font-size: .74rem;
  color: var(--muted);
  font-weight: 500;
}
.dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}
.dot-ada   { background: var(--ada); }
.dot-salon { background: var(--salon); }
.dot-both  { background: var(--both); }

/* View toggle */
.view-toggle {
  display: flex;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 7px;
  padding: 3px;
  gap: 2px;
  flex-shrink: 0;
}
.view-btn {
  background: none;
  border: none;
  padding: .3rem .75rem;
  border-radius: 5px;
  font-family: 'Montserrat', sans-serif;
  font-size: .72rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: .35rem;
  transition: all .15s;
}
.view-btn.active {
  background: var(--white);
  color: var(--dark);
  box-shadow: 0 1px 4px rgba(0,0,0,.1);
}
.view-btn svg { width: 14px; height: 14px; flex-shrink: 0; }

/* ── MAIN LAYOUT ─────────────────────────────────────── */
main {
  max-width: 1200px;
  margin: 1.5rem auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 1.5rem;
  align-items: start;
}

/* ── CALENDAR VIEW ───────────────────────────────────── */
.calendar-section {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.cal-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid var(--border);
}
.cal-nav h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--dark);
  letter-spacing: 1px;
}
.cal-nav-btn {
  background: none;
  border: 1px solid var(--border);
  width: 34px; height: 34px;
  border-radius: 50%;
  font-size: 1.3rem;
  cursor: pointer;
  color: var(--muted);
  transition: all .2s;
  display: flex; align-items: center; justify-content: center;
}
.cal-nav-btn:hover { background: var(--bg); color: var(--dark); }

.cal-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  background: var(--bg);
  border-bottom: 1px solid var(--border);
}
.cal-day-header {
  text-align: center;
  padding: .5rem 0;
  font-size: .68rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .5px;
  text-transform: uppercase;
}

.cal-body {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
}
.cal-cell {
  min-height: 80px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: .35rem .3rem;
  cursor: pointer;
  transition: background .12s;
  overflow: hidden;
}
.cal-cell:nth-child(7n) { border-right: none; }
.cal-cell:hover { background: #fdf9f4; }
.cal-cell.other-month { background: #fdfcfa; }
.cal-cell.other-month .cal-date { color: #d0cdc8; }
.cal-cell.today .cal-date {
  background: var(--gold);
  color: var(--white);
  border-radius: 50%;
}
.cal-date {
  font-size: .72rem;
  font-weight: 600;
  width: 22px; height: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto .25rem;
}

/* Event mini-labels (mobile) */
.cell-labels {
  display: flex;
  flex-direction: column;
  gap: 2px;
  margin-top: 1px;
}
.cell-label {
  font-size: .55rem;
  font-weight: 700;
  padding: 1px 3px;
  border-radius: 3px;
  color: var(--white);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1.4;
  letter-spacing: .2px;
}
/* Event pills (desktop) */
.cal-event-pill {
  display: block;
  font-size: .6rem;
  font-weight: 500;
  padding: 2px 4px;
  border-radius: 3px;
  margin-bottom: 2px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--white);
  cursor: pointer;
  max-width: 100%;
}
.pill-ada   { background: var(--ada); }
.pill-salon { background: var(--salon); }
.pill-both  { background: var(--both); }
.more-events {
  font-size: .58rem;
  color: var(--muted);
  text-align: center;
  margin-top: 1px;
}

/* ── LIST VIEW ───────────────────────────────────────── */
.list-section {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.list-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.2rem;
  border-bottom: 1px solid var(--border);
}
.list-nav h2 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--dark);
}
.list-filter {
  display: flex;
  gap: .5rem;
}
.filter-btn {
  background: var(--bg);
  border: 1px solid var(--border);
  padding: .3rem .7rem;
  border-radius: 20px;
  font-family: 'Montserrat', sans-serif;
  font-size: .68rem;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all .15s;
}
.filter-btn.active {
  background: var(--dark);
  border-color: var(--dark);
  color: var(--white);
}
.list-body { padding: 0; }
.list-month-group {}
.list-month-label {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  font-weight: 600;
  color: var(--muted);
  padding: .8rem 1.2rem .4rem;
  letter-spacing: 1px;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.list-event-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: .85rem 1.2rem;
  border-bottom: 1px solid var(--border);
  cursor: pointer;
  transition: background .12s;
}
.list-event-row:hover { background: #fdf9f4; }
.list-event-row:last-child { border-bottom: none; }
.list-date-block {
  text-align: center;
  min-width: 42px;
  flex-shrink: 0;
}
.list-date-day {
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--dark);
  line-height: 1;
}
.list-date-weekday {
  font-size: .62rem;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: .5px;
  margin-top: 2px;
}
.list-color-bar {
  width: 3px;
  height: 40px;
  border-radius: 3px;
  flex-shrink: 0;
}
.list-event-info { flex: 1; min-width: 0; }
.list-event-name {
  font-size: .85rem;
  font-weight: 600;
  color: var(--dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.list-event-meta {
  font-size: .7rem;
  color: var(--muted);
  margin-top: .25rem;
  display: flex;
  gap: .5rem;
  flex-wrap: wrap;
  align-items: center;
}
.list-badge {
  font-size: .62rem;
  padding: 1px 7px;
  border-radius: 10px;
  font-weight: 600;
  color: var(--white);
}
.badge-ada   { background: var(--ada); }
.badge-salon { background: var(--salon); }
.badge-both  { background: var(--both); }
.list-empty {
  text-align: center;
  color: var(--muted);
  font-size: .82rem;
  padding: 3rem 1rem;
}

/* ── SIDEBAR ─────────────────────────────────────────── */
.sidebar {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.2rem;
}
.sidebar-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 1rem;
  padding-bottom: .6rem;
  border-bottom: 1px solid var(--border);
}
.upcoming-list { display: flex; flex-direction: column; gap: .65rem; }
.upcoming-card {
  border-left: 3px solid var(--ada);
  padding: .55rem .75rem;
  background: var(--bg);
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  transition: opacity .2s;
}
.upcoming-card:hover { opacity: .8; }
.upcoming-card.venue-salon { border-color: var(--salon); }
.upcoming-card.venue-both  { border-color: var(--both); }
.upcoming-card-name {
  font-size: .8rem;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: .2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.upcoming-card-meta {
  font-size: .68rem;
  color: var(--muted);
  display: flex;
  gap: .4rem;
  flex-wrap: wrap;
  align-items: center;
}
.badge {
  font-size: .62rem;
  padding: 1px 6px;
  border-radius: 10px;
  font-weight: 600;
  color: var(--white);
}
.no-upcoming {
  text-align: center;
  color: var(--muted);
  font-size: .78rem;
  padding: 1.5rem 0;
}

/* ── MODAL ───────────────────────────────────────────── */
.modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.45);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}
.modal-overlay.open { display: flex; }
.modal {
  background: var(--white);
  border-radius: var(--radius);
  padding: 1.8rem;
  width: 100%;
  max-width: 520px;
  position: relative;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 20px 60px rgba(0,0,0,.2);
}
.modal-day { max-width: 400px; }
.modal-close {
  position: absolute;
  top: 1rem; right: 1rem;
  background: none;
  border: none;
  font-size: 1.4rem;
  cursor: pointer;
  color: var(--muted);
  line-height: 1;
}
.modal-close:hover { color: var(--dark); }
.modal-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--dark);
  margin-bottom: 1.4rem;
}
.form-group { margin-bottom: .9rem; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: .9rem; }
.form-group label {
  display: block;
  font-size: .7rem;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: .5px;
  text-transform: uppercase;
  margin-bottom: .3rem;
}
.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: .55rem .75rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: .83rem;
  color: var(--dark);
  background: var(--white);
  transition: border-color .2s;
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus { outline: none; border-color: var(--gold); }
.form-actions {
  display: flex;
  justify-content: flex-end;
  gap: .75rem;
  margin-top: 1.4rem;
}
.btn-save {
  background: var(--dark);
  color: var(--white);
  border: none;
  padding: .6rem 1.6rem;
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: .83rem;
  font-weight: 600;
  cursor: pointer;
  transition: opacity .2s;
}
.btn-save:hover { opacity: .8; }
.btn-delete {
  background: none;
  color: #d9534f;
  border: 1px solid #d9534f;
  padding: .6rem 1.1rem;
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: .83rem;
  font-weight: 600;
  cursor: pointer;
  transition: all .2s;
  margin-right: auto;
}
.btn-delete:hover { background: #d9534f; color: var(--white); }

/* Day modal */
.day-event-item {
  display: flex;
  align-items: flex-start;
  gap: .75rem;
  padding: .7rem;
  border-radius: 8px;
  background: var(--bg);
  margin-bottom: .5rem;
  cursor: pointer;
  transition: opacity .2s;
}
.day-event-item:hover { opacity: .8; }
.day-event-color { width: 4px; min-height: 38px; border-radius: 3px; flex-shrink: 0; }
.day-event-name { font-size: .83rem; font-weight: 600; color: var(--dark); }
.day-event-meta { font-size: .7rem; color: var(--muted); margin-top: .2rem; }
.btn-add-inline {
  width: 100%;
  margin-top: .75rem;
  background: none;
  border: 1px dashed var(--border);
  color: var(--muted);
  padding: .6rem;
  border-radius: 6px;
  font-family: 'Montserrat', sans-serif;
  font-size: .78rem;
  cursor: pointer;
  transition: all .2s;
}
.btn-add-inline:hover { border-color: var(--gold); color: var(--gold); }
.no-day-events { text-align: center; color: var(--muted); font-size: .8rem; padding: 1rem 0; }

/* ── RESPONSIVE ──────────────────────────────────────── */
@media (max-width: 900px) {
  main { grid-template-columns: 1fr; padding: 0; margin: 0; gap: 0; }
  .calendar-section,
  .list-section { border-radius: 0; box-shadow: none; }
  .sidebar {
    border-radius: 0;
    box-shadow: none;
    border-top: 1px solid var(--border);
  }
}

@media (max-width: 520px) {
  header { padding: 0 1rem; }
  .header-title { display: none; }
  .toolbar { padding: .5rem 1rem; }
  .cal-nav { padding: .8rem 1rem; }
  .cal-day-header { font-size: .6rem; padding: .4rem 0; }
  .cal-cell { min-height: 56px; padding: .25rem .2rem; }
  .cal-date { font-size: .68rem; width: 20px; height: 20px; }
  /* On mobile show mini-labels, hide pills */
  .cal-event-pill { display: none; }
  .cell-labels { display: flex; }
  .more-events { display: none; }
  .list-nav { padding: .8rem 1rem; flex-wrap: wrap; gap: .5rem; }
  .list-filter { flex-wrap: wrap; }
  .form-row { grid-template-columns: 1fr; }
  .modal { padding: 1.4rem 1.2rem; }
}

@media (min-width: 521px) {
  /* On desktop/tablet show pills, hide mini-labels */
  .cell-labels { display: none; }
}
