:root {
  --ink: #241d1b;
  --muted: #6e625d;
  --canvas: #faf7f2;
  --surface: #fffdf9;
  --surface-soft: #f4ece5;
  --line: #e5d9cf;
  --maroon: #681f2b;
  --maroon-dark: #511722;
  --gold: #b18a4c;
  --success: #25664b;
  --shadow: 0 18px 50px rgba(54, 29, 21, 0.07);
  --radius: 18px;
  --font: "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

* { box-sizing: border-box; }

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

body {
  color: var(--ink);
  background: var(--canvas);
  font-family: var(--font);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
p { color: var(--muted); line-height: 1.62; margin: 0; }
h1, h2, h3 { font-weight: 550; letter-spacing: -0.035em; margin: 0; }

.brand {
  display: inline-flex;
  gap: 7px;
  align-items: baseline;
  color: var(--maroon);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 26px;
  letter-spacing: 0.03em;
}
.brand span { color: var(--ink); font-family: var(--font); font-size: 14px; letter-spacing: 0.16em; text-transform: uppercase; }

.button {
  align-items: center;
  border: 1px solid transparent;
  border-radius: 11px;
  cursor: pointer;
  display: inline-flex;
  font: 600 14px/1 var(--font);
  height: 48px;
  justify-content: center;
  padding: 0 24px;
  transition: background .18s ease, border-color .18s ease, transform .18s ease;
}
.button:hover { transform: translateY(-1px); }
.button.primary { background: var(--maroon); color: white; }
.button.primary:hover { background: var(--maroon-dark); }
.button.subtle { border-color: var(--line); background: var(--surface); }
.button.ghost { border-color: var(--line); color: var(--maroon); }

.site-header {
  align-items: center;
  border-bottom: 1px solid var(--line);
  display: flex;
  height: 84px;
  justify-content: space-between;
  margin: 0 auto;
  max-width: 1200px;
  padding: 0 30px;
}
.site-header nav { align-items: center; display: flex; gap: 28px; color: var(--muted); font-size: 14px; }
.site-header nav a:hover { color: var(--maroon); }

.launch {
  margin: 0 auto;
  max-width: 1200px;
  padding: 84px 30px 66px;
}
.launch-copy { max-width: 720px; }
.launch h1 { font-family: Georgia, "Times New Roman", serif; font-size: clamp(43px, 5.5vw, 66px); font-weight: 500; line-height: 1.08; }
.launch-copy p { font-size: 18px; margin-top: 26px; max-width: 590px; }
.launch-actions { display: flex; gap: 14px; margin-top: 40px; }
.service-list {
  border-top: 1px solid var(--line);
  display: grid;
  gap: 42px;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 92px;
  padding-top: 42px;
}
.service-list h2 { font-size: 19px; margin-bottom: 13px; }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); font-size: 13px; margin: 0 auto; max-width: 1140px; padding: 26px 0 42px; }

.policy {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin: 68px auto;
  max-width: 800px;
  padding: clamp(34px, 6vw, 62px);
}
.policy h1, .request-card h1 { font-family: Georgia, "Times New Roman", serif; font-size: clamp(34px, 5vw, 46px); font-weight: 500; margin-bottom: 18px; }
.policy .updated { border-bottom: 1px solid var(--line); margin-bottom: 36px; padding-bottom: 30px; }
.policy h2 { font-size: 20px; margin: 31px 0 10px; }
.policy a { color: var(--maroon); text-decoration: underline; }

.request-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  margin: 68px auto;
  max-width: 620px;
  padding: clamp(34px, 6vw, 54px);
}
.request-form, .login-form { display: grid; gap: 20px; margin-top: 34px; }
.request-form label, .login-form label {
  color: var(--ink);
  display: grid;
  font-size: 13px;
  font-weight: 600;
  gap: 9px;
}
input, textarea {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  color: var(--ink);
  font: 15px/1.45 var(--font);
  padding: 13px 14px;
}
input { height: 50px; }
input:focus, textarea:focus { border-color: var(--gold); outline: 2px solid rgba(177, 138, 76, 0.15); }
.form-message { font-size: 14px; min-height: 22px; }

.admin-login {
  background: var(--canvas);
  min-height: 100vh;
}
.admin-shell {
  display: flex;
  min-height: 100vh;
}
.setup-nav {
  background: #38191c;
  color: #f9eee8;
  display: flex;
  flex-direction: column;
  flex: 0 0 238px;
  padding: 36px 18px 28px;
}
.nav-brand {
  color: #ecd4b3;
  display: block;
  font: 34px/1 Georgia, serif;
  letter-spacing: .11em;
  padding: 0 22px;
}
.nav-brand small {
  display: block;
  font: 13px/1 var(--font);
  letter-spacing: .3em;
  margin: 12px 0 58px 4px;
  text-transform: uppercase;
}
.setup-nav nav { display: grid; gap: 10px; }
.setup-nav nav a {
  border: 1px solid transparent;
  border-radius: 9px;
  color: #f4e8e2;
  font-size: 15px;
  padding: 18px 22px;
}
.setup-nav nav a.active {
  background: #68242d;
  border-color: #98424b;
}
.setup-nav > p {
  border-top: 1px solid rgba(221, 180, 110, .55);
  color: #f6e9e1;
  font-size: 14px;
  margin-top: auto;
  padding: 27px 22px 0;
}
.setup-workspace { flex: 1; }
.workspace-header {
  align-items: center;
  border-bottom: 1px solid #dcc89d;
  display: flex;
  height: 88px;
  justify-content: space-between;
  padding: 0 46px;
}
.workspace-header > span { color: var(--muted); font-size: 15px; }
.workspace-content {
  display: grid;
  grid-template-columns: minmax(600px, 1fr) 370px;
  gap: 40px;
  padding: 35px 42px;
}
.setup-main h1 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: 46px;
  font-weight: 500;
  margin-bottom: 8px;
}
.integration-grid {
  display: grid;
  gap: 15px;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  margin-top: 30px;
}
.integration-grid article {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  min-height: 285px;
  padding: 24px 16px 18px;
  text-align: center;
}
.integration-mark {
  align-items: center;
  border: 1px solid #ebd7be;
  border-radius: 50%;
  color: var(--maroon);
  display: inline-flex;
  font: 600 22px/1 Georgia, serif;
  height: 60px;
  justify-content: center;
  margin-bottom: 20px;
  width: 60px;
}
.integration-grid h2 { font: 500 19px/1.2 Georgia, serif; margin-bottom: 10px; }
.integration-grid p { font-size: 13px; min-height: 55px; }
.integration-grid span {
  background: #f8eded;
  border-radius: 7px;
  color: var(--maroon);
  display: block;
  font-size: 12px;
  margin-top: 18px;
  padding: 13px 6px;
}
.tracking-plan {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: grid;
  gap: 32px;
  grid-template-columns: 235px 1fr;
  margin-top: 26px;
  padding: 32px 28px;
}
.tracking-plan h2 { font: 500 18px/1.3 Georgia, serif; margin-bottom: 14px; }
.tracking-plan p { font-size: 13px; }
.tracking-plan ul {
  border-left: 1px solid var(--line);
  display: grid;
  gap: 22px 28px;
  grid-template-columns: 1fr 1fr;
  list-style: none;
  margin: 0;
  padding: 4px 0 4px 28px;
}
.tracking-plan strong { display: block; font: 500 16px/1.35 Georgia, serif; margin-bottom: 5px; }
.tracking-plan span { color: var(--muted); font-size: 12px; }
.auth-column {
  border-left: 1px solid #ddc99d;
  padding-left: 32px;
}
.auth-column > h2 {
  font: 500 21px/1.3 Georgia, serif;
  margin: 26px 0 40px;
  text-align: center;
}
.login-layout {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 26px;
  box-shadow: var(--shadow);
  display: grid;
  grid-template-columns: minmax(350px, 420px) 1fr;
  margin: 0 auto;
  max-width: 1200px;
  min-height: calc(100vh - clamp(36px, 8vw, 84px));
  overflow: hidden;
}
.login-panel { display: flex; flex-direction: column; padding: clamp(34px, 5vw, 50px); }
.auth-column .login-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 9px;
  box-shadow: var(--shadow);
  min-height: 565px;
  padding: 42px 24px 28px;
}
.auth-column .login-panel h3 {
  font: 500 24px/1.3 Georgia, serif;
  margin-bottom: 7px;
  text-align: center;
}
.auth-column .login-panel > p:first-of-type { font-size: 13px; text-align: center; }
.auth-column .login-form { margin-top: 35px; }
.login-copy { margin-top: auto; padding-top: 52px; }
.login-copy h1 { font-family: Georgia, "Times New Roman", serif; font-size: 43px; font-weight: 500; margin-bottom: 13px; }
.login-form .button { margin-top: 8px; width: 100%; }
.admin-note { border-top: 1px solid var(--line); font-size: 12px; margin-top: auto; padding-top: 28px; }
.alert {
  background: #faeeee;
  border: 1px solid #e6cdcd;
  border-radius: 10px;
  color: #7e2b2b;
  font-size: 13px;
  margin-top: 22px;
  padding: 12px;
}
.setup-preview {
  background: #f7f0e9;
  border-left: 1px solid var(--line);
  padding: clamp(32px, 5vw, 52px);
}
.setup-preview header { align-items: start; display: flex; justify-content: space-between; margin-bottom: 42px; }
.setup-preview h2 { font-size: 30px; margin-bottom: 8px; }
.status {
  border: 1px solid #dccbbb;
  border-radius: 100px;
  color: var(--muted);
  font-size: 12px;
  padding: 9px 14px;
}
.status.ready { background: #eaf4ed; border-color: #b5dbc5; color: var(--success); }
.status-grid { display: grid; gap: 15px; grid-template-columns: repeat(2, 1fr); }
.status-grid article {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  min-height: 155px;
  padding: 25px 23px;
}
.status-grid h3 { font-size: 18px; margin-bottom: 10px; }
.status-grid p { font-size: 13px; margin-bottom: 22px; }
.status-grid span { color: var(--maroon); font-size: 12px; font-weight: 600; text-transform: uppercase; letter-spacing: .08em; }
.event-panel {
  border-top: 1px solid var(--line);
  margin-top: 38px;
  padding-top: 29px;
}
.event-panel h3 { font-size: 18px; margin-bottom: 13px; }
.event-panel p { color: var(--ink); font-size: 14px; }

.dashboard { background: var(--canvas); display: flex; min-height: 100vh; }
.sidebar {
  background: var(--surface);
  border-right: 1px solid var(--line);
  min-width: 250px;
  padding: 30px 24px;
}
.sidebar nav { display: grid; gap: 7px; margin-top: 66px; }
.sidebar nav a { border-radius: 9px; color: var(--muted); font-size: 14px; padding: 15px 16px; }
.sidebar nav a.selected { background: var(--surface-soft); color: var(--maroon); font-weight: 600; }
.dashboard-main { flex: 1; padding: 40px clamp(28px, 5vw, 58px); }
.dashboard-header { align-items: center; display: flex; justify-content: space-between; margin-bottom: 40px; }
.dashboard-header h1 { font-size: 34px; margin-bottom: 9px; }
.dashboard-status { display: grid; gap: 16px; grid-template-columns: repeat(4, minmax(160px, 1fr)); }
.dashboard-status article, .dashboard-section {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 25px;
}
.dashboard-status h2 { font-size: 17px; margin-bottom: 32px; }
.dashboard-status .pending { color: var(--maroon); }
.dashboard-status .ok { color: var(--success); }
.dashboard-section { margin-top: 24px; max-width: 780px; }
.dashboard-section h2 { font-size: 21px; margin-bottom: 14px; }

@media (max-width: 880px) {
  .site-header nav a:not(.button) { display: none; }
  .launch { padding-top: 52px; }
  .service-list, .login-layout, .status-grid { grid-template-columns: 1fr; }
  .setup-preview { border-left: 0; border-top: 1px solid var(--line); }
  .dashboard { display: block; }
  .sidebar { min-width: 0; }
  .sidebar nav { display: flex; margin-top: 28px; overflow-x: auto; }
  .dashboard-status { grid-template-columns: 1fr 1fr; }
  .admin-shell { display: block; }
  .setup-nav { display: none; }
  .workspace-header { padding: 0 22px; }
  .workspace-content { display: block; padding: 28px 18px; }
  .integration-grid { grid-template-columns: 1fr 1fr; }
  .tracking-plan { grid-template-columns: 1fr; }
  .tracking-plan ul { border-left: 0; padding-left: 0; }
  .auth-column { border-left: 0; padding-left: 0; }
  .auth-column > h2 { margin-top: 40px; }
}

@media (max-width: 560px) {
  .site-header { padding: 0 18px; }
  .brand { font-size: 22px; }
  .launch { padding-left: 18px; padding-right: 18px; }
  .launch-actions { flex-direction: column; }
  .service-list, .dashboard-status { grid-template-columns: 1fr; }
  .setup-preview header { display: block; }
  .setup-preview .status { display: inline-block; margin-top: 20px; }
}
