:root {
  --sand: #f6f0e7;
  --ink: #15212a;
  --sea: #1f6f85;
  --foam: #e7f5f7;
  --line: rgba(21, 33, 42, 0.1);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: "Instrument Sans", system-ui, sans-serif;
}

a { color: inherit; text-decoration: none; }
img { display: block; max-width: 100%; }
button, input, textarea { font: inherit; }

.topbar {
  align-items: center;
  backdrop-filter: blur(16px);
  background: rgba(255, 255, 255, 0.84);
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  padding: 16px clamp(16px, 4vw, 48px);
  position: sticky;
  top: 0;
  z-index: 10;
}

.brand { font-weight: 700; }
.topbar nav { align-items: center; display: flex; gap: 12px; }
.topbar a, .topbar button {
  border: 0;
  border-radius: 999px;
  background: transparent;
  cursor: pointer;
  padding: 10px 16px;
}
.topbar button { background: var(--ink); color: white; }

.login {
  display: grid;
  min-height: 100vh;
}

.login-photo { display: none; position: relative; overflow: hidden; }
.login-photo img { height: 100%; width: 100%; object-fit: cover; }
.login-photo::after {
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.3), transparent);
  content: "";
  inset: 0;
  position: absolute;
}
.login-photo div {
  background: rgba(255, 255, 255, 0.86);
  border-radius: 28px;
  bottom: 40px;
  left: 40px;
  max-width: 420px;
  padding: 28px;
  position: absolute;
  z-index: 1;
}

.login-card {
  align-self: center;
  background: white;
  border-radius: 32px;
  box-shadow: 0 24px 70px rgba(21, 33, 42, 0.08);
  margin: 24px;
  overflow: hidden;
  padding: clamp(24px, 5vw, 40px);
}

.login-card-photo {
  aspect-ratio: 16 / 10;
  border-radius: 24px;
  margin: 0 0 24px;
  object-fit: cover;
  width: 100%;
}

.login-intro {
  margin-bottom: 24px;
}

.eyebrow {
  color: var(--sea);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.24em;
  margin: 0 0 12px;
  text-transform: uppercase;
}

h1, h2 { line-height: 1.1; margin: 0; }
h1 { font-size: clamp(2.4rem, 5vw, 4.5rem); }
h2 { font-size: clamp(1.7rem, 3vw, 2.5rem); }
p { color: rgba(21, 33, 42, 0.68); line-height: 1.7; }

label { display: grid; font-weight: 700; gap: 8px; margin-top: 16px; }
input, textarea {
  border: 1px solid var(--line);
  border-radius: 18px;
  outline: none;
  padding: 14px 16px;
}
select {
  background: white;
  border: 1px solid var(--line);
  border-radius: 18px;
  outline: none;
  padding: 14px 16px;
}
input:focus, textarea:focus, select:focus {
  border-color: var(--sea);
  box-shadow: 0 0 0 4px rgba(31, 111, 133, 0.12);
}

.primary, .approve {
  background: var(--sea);
  border: 0;
  border-radius: 18px;
  color: white;
  cursor: pointer;
  font-weight: 700;
  margin-top: 16px;
  padding: 14px 18px;
  width: 100%;
}

.secondary {
  background: var(--ink);
  border: 0;
  border-radius: 18px;
  color: white;
  cursor: pointer;
  font-weight: 700;
  margin-top: 16px;
  padding: 14px 18px;
}

.alert {
  background: #fff1f1;
  border: 1px solid #ffd1d1;
  border-radius: 16px;
  color: #8f1d1d;
  margin: 16px 0;
  padding: 12px 14px;
}

.page-grid, .admin-grid {
  display: grid;
  gap: 32px;
  margin: 32px auto;
  max-width: 1200px;
  padding: 0 16px;
}

.hero-card, .calendar-card, .panel {
  background: white;
  border-radius: 32px;
  box-shadow: 0 24px 70px rgba(21, 33, 42, 0.08);
  overflow: hidden;
}
.hero-card > img { aspect-ratio: 16 / 10; object-fit: cover; width: 100%; }
.hero-card > div, .calendar-card, .panel { padding: clamp(20px, 4vw, 32px); }

.stats {
  display: grid;
  gap: 12px;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 24px;
}
.stats span, .estimate, .note {
  background: var(--sand);
  border-radius: 20px;
  padding: 16px;
}
small { color: rgba(21, 33, 42, 0.55); display: block; }

.calendar-head {
  align-items: start;
  display: flex;
  gap: 16px;
  justify-content: space-between;
}
.calendar-head button {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: white;
  cursor: pointer;
  padding: 9px 12px;
}
.calendar-box {
  border: 1px solid var(--line);
  border-radius: 28px;
  margin-top: 20px;
  padding: 16px;
}
.weekdays, .days {
  display: grid;
  gap: 8px;
  grid-template-columns: repeat(7, 1fr);
}
.weekdays {
  color: rgba(21, 33, 42, 0.48);
  font-size: 0.76rem;
  font-weight: 700;
  margin: 16px 0 8px;
  text-align: center;
  text-transform: uppercase;
}
.day {
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: white;
  cursor: pointer;
  font-weight: 700;
}
.day:hover { background: var(--foam); }
.day.selected { background: var(--sea); color: white; }
.day.range { background: rgba(31, 111, 133, 0.13); }
.day.blocked {
  background: rgba(21, 33, 42, 0.08);
  color: rgba(21, 33, 42, 0.35);
  cursor: not-allowed;
  text-decoration: line-through;
}
.day.muted { opacity: 0.25; }

.two { display: grid; gap: 12px; grid-template-columns: 1fr 1fr; }
.gallery {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  margin: 0 auto 32px;
  max-width: 1200px;
  padding: 0 16px;
}
.gallery img {
  aspect-ratio: 4 / 3;
  border-radius: 28px;
  box-shadow: 0 14px 40px rgba(21, 33, 42, 0.08);
  object-fit: cover;
  width: 100%;
}
.panel {
  margin: 0 auto 32px;
  max-width: 1200px;
}
.row {
  align-items: center;
  border: 1px solid var(--line);
  border-radius: 20px;
  display: flex;
  justify-content: space-between;
  margin-top: 12px;
  padding: 16px;
}
.admin {
  margin: 32px auto;
  max-width: 1200px;
  padding: 0 16px;
}
.request {
  border: 1px solid var(--line);
  border-radius: 24px;
  margin-top: 16px;
  padding: 18px;
}
.request textarea { width: 100%; }
.section-head {
  align-items: start;
  display: grid;
  gap: 16px;
  grid-template-columns: 1fr;
  margin-bottom: 24px;
}
.user-management {
  background:
    radial-gradient(circle at top right, rgba(31, 111, 133, 0.12), transparent 34%),
    white;
  margin-top: 32px;
}
.user-form {
  background: linear-gradient(135deg, var(--sand), var(--foam));
  border: 1px solid rgba(31, 111, 133, 0.12);
  border-radius: 24px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
  padding: 20px;
}
.user-list {
  display: grid;
  gap: 16px;
  margin-top: 24px;
}
.user-row {
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(21, 33, 42, 0.08);
  border-radius: 24px;
  box-shadow: 0 14px 36px rgba(21, 33, 42, 0.06);
  display: grid;
  gap: 20px;
  padding: 20px;
}
.user-actions {
  align-content: start;
  background: linear-gradient(180deg, var(--foam), rgba(231, 245, 247, 0.45));
  border-radius: 20px;
  display: grid;
  gap: 10px;
  padding: 16px;
}
.user-actions strong {
  font-size: 1.05rem;
}
.user-actions small {
  line-height: 1.5;
}
.user-edit .secondary {
  width: 100%;
}
.reject, .link-danger {
  background: #fff1f1;
  border: 1px solid #ffd1d1;
  border-radius: 16px;
  color: #8f1d1d;
  cursor: pointer;
  font-weight: 700;
  margin-top: 12px;
  padding: 12px 14px;
}

@media (min-width: 900px) {
  .login { grid-template-columns: 1.1fr 0.9fr; }
  .login-photo { display: block; }
  .login-card-photo { display: none; }
  .page-grid { grid-template-columns: 1.05fr 0.95fr; }
  .admin-grid { grid-template-columns: 1fr 0.85fr; padding: 0; }
  .section-head { grid-template-columns: 0.85fr 1fr; }
  .user-row { grid-template-columns: 1fr 280px; }
}

@media (max-width: 640px) {
  .topbar, .topbar nav, .calendar-head, .row { align-items: stretch; flex-direction: column; }
  .two, .stats { grid-template-columns: 1fr; }
}
