:root {
  color-scheme: light;
  --bg: #f6f7f9;
  --panel: #ffffff;
  --ink: #162033;
  --muted: #5b6472;
  --line: #d9dee7;
  --accent: #0f766e;
  --accent-strong: #0b5f59;
  --danger: #b42318;
  --focus: #f59e0b;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.5;
}

.page {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 24px 0 56px;
}

.header {
  padding: 18px 0 22px;
}

.header h1 {
  margin: 0 0 8px;
  font-size: clamp(1.35rem, 3vw, 2rem);
  line-height: 1.1;
}

.conference-title {
  font-size: clamp(1.75rem, 4vw, 2.7rem);
  line-height: 1.1;
  font-weight: 700;
}

.header p {
  margin: 0 0 18px;
  color: var(--muted);
}

.hotel-details {
  margin-bottom: 0;
}

.conference-program {
  text-align: center;
}

.header .registration-closed {
  max-width: 760px;
  margin: 32px auto 0;
  border-left: 5px solid #eab308;
  background: #fff8db;
  color: var(--ink);
  padding: 20px 22px;
  font-size: clamp(1.15rem, 2.5vw, 1.4rem);
  text-align: center;
}

.notice,
.success {
  border-left: 5px solid var(--accent);
  background: var(--panel);
  padding: 16px 18px;
  margin: 16px 0;
}

.submission-info {
  border-left: 5px solid #eab308;
  background: #fff8db;
  padding: 16px 18px;
}

.submission-info p {
  margin: 0 0 12px;
}

.submission-info p:last-child {
  margin-bottom: 0;
}

.admin-page {
  width: min(1280px, calc(100% - 32px));
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 18px 0 22px;
}

.admin-header h1 {
  margin: 0 0 4px;
  font-size: clamp(1.5rem, 3vw, 2.2rem);
}

.admin-nav {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

.admin-card {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 8px;
  padding: 18px;
  margin-bottom: 16px;
}

.admin-search {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  align-items: end;
}

.admin-table-head,
.admin-pagination {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
}

.table-scroll {
  overflow-x: auto;
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 860px;
}

.admin-table th,
.admin-table td {
  border-bottom: 1px solid var(--line);
  padding: 10px;
  text-align: left;
  vertical-align: top;
}

.admin-table th {
  color: var(--muted);
  font-size: 0.9rem;
}

.admin-details {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: 0;
}

.admin-details dt,
.admin-details dd {
  border-bottom: 1px solid var(--line);
  margin: 0;
  padding: 10px 0;
}

.admin-details dt {
  color: var(--muted);
  font-weight: 700;
}

.form-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 18px;
  align-items: start;
}

form {
  display: grid;
  gap: 16px;
}

fieldset,
.summary {
  border: 1px solid var(--line);
  background: var(--panel);
  border-radius: 8px;
  padding: 18px;
}

legend {
  padding: 0 8px;
  font-weight: 700;
}

.fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

label,
.choice-title {
  display: block;
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  margin-top: 6px;
  border: 1px solid #b7c0cd;
  border-radius: 6px;
  padding: 11px 12px;
  font: inherit;
  background: #fff;
}

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

input:focus,
textarea:focus {
  outline: 3px solid color-mix(in srgb, var(--focus) 45%, transparent);
  border-color: var(--focus);
}

.full {
  grid-column: 1 / -1;
}

.choices {
  display: grid;
  gap: 10px;
  margin-top: 10px;
}

.choice {
  display: grid;
  grid-template-columns: 22px 1fr auto;
  gap: 10px;
  align-items: start;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 12px;
}

.choice input {
  width: auto;
  margin-top: 4px;
}

.price {
  color: var(--accent-strong);
  font-weight: 700;
  white-space: nowrap;
}

.help {
  color: var(--muted);
  font-size: 0.95rem;
}

.section-gap,
.declaration-gap {
  margin-top: 18px;
}

.error {
  color: var(--danger);
  font-weight: 700;
  margin-top: 6px;
}

.summary {
  position: sticky;
  top: 16px;
}

.total {
  display: block;
  margin-top: 8px;
  color: var(--accent-strong);
  font-size: 2rem;
  font-weight: 800;
}

.actions {
  display: flex;
  justify-content: flex-end;
}

button {
  border: 0;
  border-radius: 8px;
  padding: 13px 20px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}

button:hover {
  background: var(--accent-strong);
}

@media (max-width: 860px) {
  .page {
    width: min(100% - 22px, 680px);
  }

  .form-grid,
  .fields {
    grid-template-columns: 1fr;
  }

  .summary {
    position: static;
    order: -1;
  }

  .choice {
    grid-template-columns: 22px 1fr;
  }

  .price {
    grid-column: 2;
  }

  .admin-header,
  .admin-table-head,
  .admin-pagination {
    align-items: flex-start;
    flex-direction: column;
  }

  .admin-search,
  .admin-details {
    grid-template-columns: 1fr;
  }

  .admin-details dt {
    border-bottom: 0;
    padding-bottom: 2px;
  }

  .admin-details dd {
    padding-top: 0;
  }
}
