@import url("https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600;700;800&family=DM+Serif+Display:ital@0;1&display=swap");

:root {
  --font-body: "Manrope", "Avenir Next", "Segoe UI", sans-serif;
  --font-title: "DM Serif Display", Georgia, serif;

  --bg-ink: #f2f6f7;
  --bg-ink-soft: #e7f0f2;
  --surface: #ffffff;
  --surface-strong: #f8fbfc;
  --text-strong: #13222b;
  --text-soft: #5c707a;

  --brand: #0f766e;
  --brand-strong: #0a5b55;
  --brand-soft: #d9f2ef;

  --danger: #be2f39;
  --danger-strong: #9a1f27;

  --line: #d6e3e8;
  --line-strong: #bfd1d8;

  --shadow-soft: 0 18px 32px rgba(19, 34, 43, 0.08);
  --shadow-strong: 0 22px 46px rgba(16, 31, 39, 0.14);
}

* {
  box-sizing: border-box;
}

html,
body {
  min-height: 100%;
}

body {
  margin: 0;
  color: var(--text-strong);
  font-family: var(--font-body);
  background:
    radial-gradient(1200px 600px at 8% -10%, #d5ebe8 0%, transparent 58%),
    radial-gradient(1000px 640px at 102% 0%, #dbe9f7 0%, transparent 52%),
    linear-gradient(180deg, var(--bg-ink-soft) 0%, var(--bg-ink) 42%, #f8fbfc 100%);
  position: relative;
}

body::before,
body::after {
  content: "";
  position: fixed;
  z-index: 0;
  border-radius: 999px;
  pointer-events: none;
  filter: blur(2px);
}

body::before {
  width: 320px;
  height: 320px;
  right: -90px;
  top: 90px;
  background: radial-gradient(circle at 30% 30%, rgba(15, 118, 110, 0.24), rgba(15, 118, 110, 0));
}

body::after {
  width: 260px;
  height: 260px;
  left: -80px;
  bottom: 60px;
  background: radial-gradient(circle at 50% 50%, rgba(60, 130, 191, 0.22), rgba(60, 130, 191, 0));
}

.container {
  position: relative;
  z-index: 1;
  max-width: 1120px;
  margin: 0 auto;
  padding: 34px 20px 56px;
  animation: fade-in-up 0.5s ease both;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 16px;
  margin-bottom: 20px;
}

.title-wrap {
  display: grid;
  gap: 2px;
}

.eyebrow {
  margin: 0;
  color: #295865;
  font-size: 0.74rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 800;
}

.header h1 {
  margin: 0;
  font-family: var(--font-title);
  letter-spacing: 0.01em;
  font-size: clamp(1.75rem, 2.8vw, 2.45rem);
  line-height: 1.05;
  color: #0e2028;
}

.header-subtitle {
  margin: 4px 0 0;
  color: var(--text-soft);
  font-size: 0.94rem;
}

.link-admin {
  text-decoration: none;
  color: #17414d;
  border: 1px solid var(--line-strong);
  background: linear-gradient(180deg, #ffffff, #edf4f6);
  box-shadow: 0 8px 14px rgba(18, 38, 47, 0.08);
  border-radius: 999px;
  padding: 10px 14px;
  font-weight: 700;
  font-size: 0.89rem;
  transition: transform 0.18s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.link-admin:hover {
  transform: translateY(-1px);
  border-color: #98b8c2;
  box-shadow: 0 10px 18px rgba(18, 38, 47, 0.12);
}

.card {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: linear-gradient(180deg, #ffffff 0%, var(--surface-strong) 100%);
  box-shadow: var(--shadow-soft);
  padding: 20px 22px;
  margin-bottom: 14px;
  animation: fade-in-up 0.45s ease both;
}

.card:nth-of-type(2) {
  animation-delay: 0.07s;
}

.card:nth-of-type(3) {
  animation-delay: 0.14s;
}

h2 {
  margin: 0 0 12px;
  font-size: 1.15rem;
  font-weight: 800;
  color: #10252f;
}

.row {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.row-space {
  justify-content: space-between;
}

input,
select,
button {
  font-family: inherit;
  border-radius: 11px;
  font-size: 0.93rem;
}

input,
select {
  flex: 1 1 230px;
  min-width: 220px;
  background: #fbfdfe;
  border: 1px solid var(--line);
  color: var(--text-strong);
  padding: 11px 12px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input::placeholder {
  color: #8aa0aa;
}

input:focus,
select:focus {
  border-color: #6ea8ba;
  box-shadow: 0 0 0 3px rgba(110, 168, 186, 0.2);
}

button {
  border: 1px solid transparent;
  padding: 11px 14px;
  color: #f8fefe;
  background: linear-gradient(180deg, var(--brand) 0%, var(--brand-strong) 100%);
  box-shadow: 0 10px 16px rgba(8, 68, 64, 0.2);
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.16s ease, filter 0.16s ease, box-shadow 0.18s ease;
}

button:hover {
  transform: translateY(-1px);
  filter: brightness(1.02);
  box-shadow: 0 14px 22px rgba(8, 68, 64, 0.24);
}

button.secondary {
  color: #1f3842;
  border-color: var(--line-strong);
  background: linear-gradient(180deg, #ffffff 0%, #eaf2f5 100%);
  box-shadow: 0 8px 14px rgba(26, 49, 59, 0.12);
}

button.secondary:hover {
  box-shadow: 0 12px 18px rgba(26, 49, 59, 0.16);
}

button.danger {
  background: linear-gradient(180deg, var(--danger) 0%, var(--danger-strong) 100%);
  box-shadow: 0 10px 16px rgba(108, 22, 30, 0.24);
}

button:disabled {
  transform: none;
  opacity: 0.54;
  cursor: not-allowed;
  box-shadow: none;
}

.muted {
  color: var(--text-soft);
  margin: 10px 0 0;
  line-height: 1.45;
}

#bookingRule {
  font-weight: 600;
  color: #1f5458;
}

.hidden {
  display: none;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  margin-top: 12px;
  background: #fcfeff;
}

table {
  width: 100%;
  border-collapse: collapse;
}

th,
td {
  padding: 11px 10px;
  border-bottom: 1px solid #e1ebef;
  text-align: left;
  vertical-align: middle;
}

th {
  font-size: 0.77rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #49616a;
  background: #eef5f8;
  font-weight: 800;
}

tbody tr:hover {
  background: #f4fafb;
}

tbody tr:last-child td {
  border-bottom: none;
}

.table-wrap button {
  padding: 8px 10px;
  font-size: 0.84rem;
  border-radius: 9px;
}

.badge {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 4px 9px;
  margin: 2px 4px 2px 0;
  border: 1px solid #c8dde7;
  background: linear-gradient(180deg, #edf7fb, #e4f1f7);
  color: #265267;
  font-size: 0.79rem;
  font-weight: 700;
}

.status-ok {
  color: #0d7d56;
  font-weight: 800;
}

.status-full {
  color: #b3353f;
  font-weight: 800;
}

.toast {
  min-height: 24px;
  margin: 8px 0 0;
  border-radius: 10px;
  padding: 7px 10px;
  background: #eaf3f6;
  border: 1px solid #cfe0e6;
  color: #1f3b47;
  font-weight: 700;
}

.toast.error {
  color: #8c1f29;
  background: #fdeef0;
  border-color: #f2c7cd;
}

.toast.success {
  color: #0d6848;
  background: #e7f8f1;
  border-color: #bee8d7;
}

.collaborator-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 12px;
  border: 1px solid var(--line);
  background: #fafdfe;
  border-radius: 12px;
  padding: 10px 11px;
  margin-bottom: 8px;
}

.collaborator-item strong {
  font-size: 0.97rem;
}

.collaborator-item .muted {
  margin-top: 2px;
  font-size: 0.84rem;
}

.capacity-input {
  width: 94px;
  min-width: 94px;
}

@keyframes fade-in-up {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 840px) {
  .container {
    padding-top: 24px;
  }

  .header {
    flex-direction: column;
    align-items: flex-start;
  }

  .link-admin {
    align-self: flex-start;
  }
}

@media (max-width: 720px) {
  .card {
    padding: 16px;
    border-radius: 14px;
  }

  input,
  select,
  button {
    width: 100%;
    min-width: 0;
  }

  .row {
    flex-direction: column;
    align-items: stretch;
  }

  .collaborator-item {
    flex-direction: column;
  }

  .collaborator-item .row {
    width: 100%;
  }

  .toast {
    font-size: 0.9rem;
  }
}
