:root {
  --bg: #f4f7fb;
  --panel: #ffffff;
  --panel-soft: #eef4ff;
  --text: #1f2937;
  --muted: #687385;
  --primary: #1d4ed8;
  --primary-dark: #1e3a8a;
  --line: #dfe7f3;
  --success: #0f9f6e;
  --shadow: 0 24px 60px rgba(15, 23, 42, 0.12);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  display: grid;
  place-items: center;
  font-family: "Inter", sans-serif;
  background: linear-gradient(135deg, #eef4ff 0%, #f8fafc 45%, #ecfeff 100%);
  color: var(--text);
}

.page-shell {
  width: min(1200px, calc(100% - 32px));
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow: hidden;
  padding: 24px;
  backdrop-filter: blur(8px);
}

.admin-link-btn,
.admin-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  border-radius: 999px;
  background: #eef4ff;
  color: var(--primary-dark);
  font-weight: 700;
  padding: 14px 20px;
}

.form-panel,
.admin-panel,
.login-card {
  background: var(--panel);
  border-radius: 22px;
  border: 1px solid rgba(148, 163, 184, 0.14);
}

.form-panel {
  padding: 52px 46px;
}

.admin-panel {
  padding: 28px 24px 20px;
}

.brand-block {
  margin-bottom: 28px;
}

.brand-logo {
  display: block;
  width: 150px;
  height: auto;
  margin-bottom: 18px;
}

.eyebrow {
  display: inline-block;
  font-size: 0.76rem;
  letter-spacing: 0.18em;
  font-weight: 800;
  color: var(--primary);
  margin-bottom: 10px;
}

.eyebrow.small {
  letter-spacing: 0.12em;
  margin-bottom: 6px;
}

.brand-block h1,
.admin-header h2 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 3vw, 3.2rem);
  line-height: 1.04;
  letter-spacing: -0.06em;
}

.brand-block p {
  margin: 0;
  max-width: 630px;
  color: var(--muted);
  line-height: 1.7;
}

#contactForm {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

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

.field-row.single {
  grid-template-columns: 1fr;
}

label {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text);
}

input,
textarea,
select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 14px 16px;
  font: inherit;
  color: var(--text);
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

input::placeholder,
textarea::placeholder {
  color: #94a3b8;
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: rgba(29, 78, 216, 0.45);
  box-shadow: 0 0 0 4px rgba(29, 78, 216, 0.09);
}

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

select {
  appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, #64748b 50%), linear-gradient(135deg, #64748b 50%, transparent 50%);
  background-position: calc(100% - 18px) calc(50% - 2px), calc(100% - 12px) calc(50% - 2px);
  background-size: 6px 6px, 6px 6px;
  background-repeat: no-repeat;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 8px;
}

.submit-btn,
.secondary-btn {
  border: none;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  padding: 15px 24px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.submit-btn {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: #fff;
  box-shadow: 0 18px 28px rgba(29, 78, 216, 0.24);
}

.secondary-btn {
  background: #eef4ff;
  color: var(--primary-dark);
}

.submit-btn:hover,
.secondary-btn:hover {
  transform: translateY(-1px);
}

.form-status {
  min-height: 22px;
  margin: 0;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--muted);
}

.form-status.success {
  color: var(--success);
}

.form-status.error {
  color: #dc2626;
}

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

.admin-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-radius: 16px;
  background: rgba(29, 78, 216, 0.06);
  border: 1px solid rgba(29, 78, 216, 0.08);
  color: var(--primary-dark);
  font-weight: 600;
  margin-bottom: 18px;
}

.admin-summary strong {
  font-size: 1.4rem;
}

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

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.94rem;
}

thead {
  background: #f8fafc;
}

th,
td {
  text-align: left;
  padding: 12px 14px;
  border-bottom: 1px solid #e5e7eb;
  vertical-align: top;
}

th {
  font-size: 0.8rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.empty-state {
  color: var(--muted);
  text-align: center;
  padding: 24px 12px;
}

.login-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 32px 16px;
}

.login-card {
  width: min(460px, 100%);
  padding: 32px 28px;
  box-shadow: var(--shadow);
}

.login-card h1 {
  font-size: clamp(2rem, 3vw, 2.5rem);
  margin: 0 0 6px;
}

.login-form {
  display: grid;
  gap: 16px;
  margin-top: 18px;
}

.login-form button {
  width: 100%;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: white;
  font: inherit;
  font-weight: 700;
  padding: 14px 16px;
  cursor: pointer;
}

.hidden {
  display: none !important;
}

@media (max-width: 820px) {
  .field-row {
    grid-template-columns: 1fr;
  }

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

  .form-panel,
  .admin-panel,
  .login-card {
    padding: 24px 18px;
  }
}
