/* ============================================================
   AURA NAILS — Modern Design System v2
   Refresh: Shadows, Animations, Gradients, High Contrast
   Farby: Taupe (#9d8b7e) + Espresso (#3d3d3d) primárne
   ============================================================ */

/* Import existing color system */
@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;1,400;1,500&family=Jost:wght@300;400;500&display=swap');

:root {
  /* ---- LEGACY COMPAT (used throughout app.jsx via inline styles) ---- */
  --porcelain: #F7F2EF;
  --cream: #EEE6E1;
  --sand: #E2D7D0;
  --beige: #D3C3BA;
  --blush: #DEC8C0;
  --ink: #3E2727;
  --ink-2: #6E5B55;
  --ink-3: #9D8B84;
  --mocha: #8C6E62;
  --espresso-deep: #1F1513;
  --line: rgba(62, 39, 39, 0.10);
  --line-gold: rgba(62, 39, 39, 0.30);
  --line-accent: rgba(62, 39, 39, 0.30);
  --veil: rgba(31, 21, 19, 0.45);
  --glass: rgba(247, 242, 239, 0.72);

  /* ---- AURA PALETTE (updated) ---- */
  --taupe: #9d8b7e;
  --taupe-dark: #7a6b5e;
  --taupe-light: #c7b8ac;
  --espresso: #3d3d3d;
  --espresso-light: #5a5a5a;
  --white: #faf8f6;
  --text: #2c2c2a;
  --border: #e8e6e1;

  /* ---- SEMANTIC ---- */
  --bg: #faf8f6;
  --bg-raised: #ffffff;
  --fg: #2c2c2a;
  --fg-soft: #6e5b55;
  --fg-muted: #9d8b7e;

  /* ---- TYPOGRAPHY ---- */
  --font-display: "Cormorant Garamond", serif;
  --font-sans: "Jost", system-ui, sans-serif;

  /* ---- SHADOWS (modern, diffuse, warm-tinted) ---- */
  --shadow-xs: 0 1px 2px rgba(61, 61, 61, 0.04);
  --shadow-sm: 0 2px 4px rgba(61, 61, 61, 0.08);
  --shadow-md: 0 4px 12px rgba(61, 61, 61, 0.12);
  --shadow-lg: 0 8px 24px rgba(61, 61, 61, 0.16);
  --shadow-xl: 0 12px 32px rgba(61, 61, 61, 0.20);
  --shadow-2xl: 0 20px 48px rgba(61, 61, 61, 0.24);

  /* ---- ANIMATIONS ---- */
  --dur-fast: 0.15s;
  --dur-base: 0.3s;
  --dur-slow: 0.5s;
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);

  /* ---- SPACING ---- */
  --sp-xs: 4px;
  --sp-sm: 8px;
  --sp-md: 12px;
  --sp-lg: 16px;
  --sp-xl: 24px;
  --sp-2xl: 32px;

  /* ---- RADII ---- */
  --r-xs: 4px;
  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 24px;
  --r-full: 999px;
}

/* ============================================================
   BASE STYLES
   ============================================================ */

* {
  box-sizing: border-box;
}

html, body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  padding: 0;
  margin: 0;
}

input, textarea {
  font-family: inherit;
}

/* ============================================================
   BUTTON STYLES
   ============================================================ */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 20px;
  border-radius: var(--r-md);
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  transition: all var(--dur-base) var(--ease);
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: linear-gradient(135deg, var(--taupe-dark), var(--taupe));
  color: white;
  box-shadow: var(--shadow-md);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-secondary {
  background: white;
  color: var(--taupe-dark);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover {
  background: var(--taupe-light);
  color: white;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-ghost {
  background: transparent;
  color: var(--taupe-dark);
  border: 1px dashed var(--border);
}

.btn-ghost:hover {
  background: rgba(199, 184, 172, 0.1);
}

/* ============================================================
   CARDS & CONTAINERS
   ============================================================ */

.card {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  padding: var(--sp-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--dur-base) var(--ease);
}

.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.card-elevated {
  box-shadow: var(--shadow-lg);
}

/* ============================================================
   INPUTS
   ============================================================ */

input[type="text"],
input[type="email"],
input[type="password"],
input[type="date"],
input[type="time"],
input[type="number"],
textarea,
select {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-raised);
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  transition: all var(--dur-fast) var(--ease);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--taupe);
  box-shadow: 0 0 0 3px rgba(157, 139, 126, 0.1);
}

input:disabled,
textarea:disabled {
  background: #f5f3f0;
  color: var(--fg-muted);
  cursor: not-allowed;
}

textarea {
  resize: vertical;
  min-height: 80px;
}

/* ============================================================
   TYPOGRAPHY
   ============================================================ */

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  color: var(--text);
  line-height: 1.2;
  margin: 0;
}

h1 {
  font-size: 2rem;
  font-weight: 400;
}

h2 {
  font-size: 1.6rem;
  font-weight: 400;
}

h3 {
  font-size: 1.3rem;
  font-weight: 500;
}

h4 {
  font-size: 1.05rem;
  font-weight: 500;
}

.eyebrow {
  font-size: 11px;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--taupe-dark);
  font-weight: 600;
}

.lead {
  font-size: 1.1rem;
  color: var(--fg-soft);
  line-height: 1.7;
}

p {
  font-size: 14px;
  color: var(--fg-soft);
  line-height: 1.7;
  margin: 0;
}

.text-small {
  font-size: 12px;
  color: var(--fg-muted);
}

/* ============================================================
   CALENDAR & DATE PICKERS
   ============================================================ */

.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 8px;
}

.calendar-day {
  aspect-ratio: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--border);
  border-radius: var(--r-md);
  background: var(--bg-raised);
  font-weight: 600;
  cursor: pointer;
  transition: all var(--dur-base) var(--ease);
  position: relative;
  min-height: 48px;
}

.calendar-day:hover:not(.disabled) {
  border-color: var(--taupe);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.calendar-day.selected {
  background: linear-gradient(135deg, var(--taupe-dark), var(--taupe));
  color: white;
  border-color: var(--taupe-dark);
  box-shadow: var(--shadow-lg);
}

.calendar-day.disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

.calendar-day.has-events::after {
  content: '';
  position: absolute;
  bottom: 4px;
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--taupe);
}

/* ============================================================
   TIME SLOTS
   ============================================================ */

.time-slot {
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  background: var(--bg-raised);
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  transition: all var(--dur-base) var(--ease);
}

.time-slot:hover:not(.disabled) {
  border-color: var(--taupe);
  background: rgba(199, 184, 172, 0.05);
  box-shadow: var(--shadow-sm);
}

.time-slot.selected {
  background: var(--taupe);
  color: white;
  border-color: var(--taupe-dark);
  box-shadow: var(--shadow-md);
}

.time-slot.disabled {
  opacity: 0.3;
  cursor: not-allowed;
}

/* ============================================================
   NOTIFICATIONS & ALERTS
   ============================================================ */

.notification {
  padding: var(--sp-lg);
  border-radius: var(--r-lg);
  margin-bottom: var(--sp-lg);
  display: flex;
  gap: var(--sp-md);
  align-items: flex-start;
  animation: slideDown 0.3s var(--ease-out);
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.notification-success {
  background: linear-gradient(135deg, rgba(157, 139, 126, 0.1), rgba(122, 107, 94, 0.05));
  border-left: 4px solid var(--taupe);
  color: var(--taupe-dark);
}

.notification-warning {
  background: linear-gradient(135deg, rgba(240, 173, 78, 0.1), rgba(240, 173, 78, 0.05));
  border-left: 4px solid #f0ad4e;
  color: #856404;
}

.notification-error {
  background: linear-gradient(135deg, rgba(217, 84, 79, 0.1), rgba(217, 84, 79, 0.05));
  border-left: 4px solid #d9534f;
  color: #b23b3b;
}

.notification-info {
  background: linear-gradient(135deg, rgba(61, 61, 61, 0.08), rgba(61, 61, 61, 0.04));
  border-left: 4px solid var(--espresso);
  color: var(--espresso);
}

.notification-icon {
  font-size: 20px;
  flex-shrink: 0;
  margin-top: 2px;
}

.notification-content {
  flex: 1;
}

.notification-title {
  font-weight: 600;
  font-size: 14px;
  margin-bottom: 4px;
}

.notification-text {
  font-size: 13px;
  line-height: 1.5;
}

/* ============================================================
   TABS
   ============================================================ */

.tabs {
  display: flex;
  gap: var(--sp-lg);
  border-bottom: 1px solid var(--border);
  margin-bottom: var(--sp-lg);
  overflow-x: auto;
}

.tab-btn {
  padding: var(--sp-md) 0;
  border: none;
  background: none;
  color: var(--fg-muted);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  border-bottom: 2px solid transparent;
  transition: all var(--dur-base) var(--ease);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  white-space: nowrap;
}

.tab-btn:hover {
  color: var(--taupe);
}

.tab-btn.active {
  color: var(--espresso);
  border-bottom-color: var(--espresso);
}

/* ============================================================
   SERVICE CARDS
   ============================================================ */

.service-card {
  display: flex;
  align-items: center;
  gap: var(--sp-lg);
  padding: var(--sp-lg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg-raised);
  cursor: pointer;
  transition: all var(--dur-base) var(--ease);
}

.service-card:hover {
  border-color: var(--taupe);
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.service-card.selected {
  background: linear-gradient(135deg, rgba(199, 184, 172, 0.15), rgba(122, 107, 94, 0.08));
  border-color: var(--taupe);
  box-shadow: var(--shadow-lg);
}

.service-card-info {
  flex: 1;
}

.service-card-name {
  font-weight: 600;
  color: var(--text);
  margin-bottom: 4px;
}

.service-card-desc {
  font-size: 12px;
  color: var(--fg-muted);
}

.service-card-duration {
  font-size: 13px;
  color: var(--taupe);
  font-weight: 500;
}

/* ============================================================
   LOADING & EMPTY STATES
   ============================================================ */

.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--taupe-light);
  border-top-color: var(--espresso);
  border-radius: 50%;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.loading-screen {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sp-xl);
  padding: var(--sp-2xl);
  text-align: center;
  min-height: 300px;
}

.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: var(--sp-lg);
  padding: var(--sp-2xl);
  text-align: center;
  color: var(--fg-muted);
}

.empty-icon {
  font-size: 56px;
  opacity: 0.3;
}

/* ============================================================
   HEADER & NAVIGATION
   ============================================================ */

.header {
  background: var(--espresso);
  color: white;
  padding: var(--sp-lg) var(--sp-xl);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: var(--sp-lg);
  box-shadow: var(--shadow-md);
}

.header-title {
  flex: 1;
}

.header-title h1 {
  color: white;
  font-size: 1.8rem;
  margin: 0;
}

.header-eyebrow {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  opacity: 0.8;
  margin-bottom: 4px;
}

.header-icon {
  width: 40px;
  height: 40px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--dur-base) var(--ease);
}

.header-icon:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: white;
}

.nav-bar {
  display: flex;
  justify-content: space-around;
  align-items: center;
  padding: var(--sp-md) 0;
  border-top: 1px solid var(--border);
  margin-top: auto;
}

.nav-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  color: var(--fg-muted);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: color var(--dur-base) var(--ease);
  flex: 1;
}

.nav-item:hover {
  color: var(--taupe);
}

.nav-item.active {
  color: var(--espresso);
}

.nav-icon {
  font-size: 16px;
}

/* ============================================================
   MODALS & OVERLAYS
   ============================================================ */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  animation: fadeIn 0.2s var(--ease);
}

@keyframes fadeIn {
  from {
    opacity: 0;
  }
  to {
    opacity: 1;
  }
}

.modal {
  background: var(--bg-raised);
  border-radius: var(--r-xl);
  padding: var(--sp-2xl);
  max-width: 90%;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-2xl);
  animation: slideUp 0.3s var(--ease-out);
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 768px) {
  .calendar-grid {
    grid-template-columns: repeat(4, 1fr);
  }

  h1 {
    font-size: 1.5rem;
  }

  h2 {
    font-size: 1.3rem;
  }

  .modal {
    max-width: 95%;
  }
}

@media (max-width: 480px) {
  .calendar-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .header {
    padding: var(--sp-md) var(--sp-lg);
  }

  .card {
    padding: var(--sp-md);
  }
}


/* ---- MONTH CALENDAR (Apple-style circular days) ---- */
.cal-month-nav { display:flex; align-items:center; justify-content:space-between; margin-bottom:10px; }
.cal-month-nav button { all:unset; cursor:pointer; width:30px; height:30px; border-radius:50%; background:rgba(120,120,128,.12); color:var(--espresso); font-size:15px; font-weight:600; display:flex; align-items:center; justify-content:center; }
.cal-month-nav span { font-size:15px; color:var(--ink); font-weight:600; font-family:var(--font-sans); }
.cal-dow-row { display:grid; grid-template-columns:repeat(7,1fr); margin-bottom:4px; }
.cal-dow-row span { text-align:center; font-size:11px; color:var(--ink-3); font-weight:590; text-transform:uppercase; }
.cal-grid { display:grid; grid-template-columns:repeat(7,1fr); gap:2px; }
.cal-day { all:unset; cursor:pointer; aspect-ratio:1; display:flex; align-items:center; justify-content:center; position:relative; box-sizing:border-box; }
.cal-day-circle { width:34px; height:34px; border-radius:50%; display:flex; align-items:center; justify-content:center; font-size:15px; color:var(--ink); font-weight:500; font-family:var(--font-sans); transition:background .15s; }
.cal-day.today .cal-day-circle { box-shadow:inset 0 0 0 1.5px var(--espresso); font-weight:700; }
.cal-day.selected .cal-day-circle { background:var(--espresso); color:var(--porcelain); font-weight:600; }
.cal-day.muted .cal-day-circle { color:var(--ink-3); opacity:.4; }
.cal-day.disabled { cursor:not-allowed; }
.cal-day.disabled .cal-day-circle { color:var(--ink-3); opacity:.35; text-decoration:line-through; }
.cal-dot { position:absolute; bottom:2px; width:4px; height:4px; border-radius:50%; background:var(--taupe); left:50%; transform:translateX(-50%); }
.cal-day.selected .cal-dot { background:var(--porcelain); }
.cal-sheet { margin-top:16px; background:rgba(120,120,128,.08); border-radius:20px; padding:14px; }
