/* Shared CMS design. Public website styles are deliberately not loaded here. */
:root {
  --green: #087a55;
  --deep: #123e33;
  --brown: #8b4535;
  --ink: #233d34;
  --muted: #718079;
  --line: #e1e8e3;
  --canvas: #f5f7f4;
  --radius: 14px;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    sans-serif;
  background: var(--canvas);
  color: var(--ink);
  font-size: 14px;
  line-height: 1.6;
}
a {
  color: var(--green);
  text-decoration: none;
}
button,
input,
textarea,
select {
  font: inherit;
}
button,
a,
input,
textarea,
select {
  -webkit-tap-highlight-color: transparent;
}
a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
select:focus-visible,
summary:focus-visible {
  outline: 3px solid #bd806b;
  outline-offset: 3px;
}
button {
  cursor: pointer;
}
h1,
h2,
h3,
p {
  margin-top: 0;
}
h1 {
  font-size: clamp(26px, 3vw, 36px);
  line-height: 1.2;
  letter-spacing: -1.2px;
  margin-bottom: 10px;
}
h2 {
  font-size: 18px;
  letter-spacing: -0.3px;
  margin-bottom: 10px;
}
h3 {
  font-size: 16px;
}
p {
  color: var(--muted);
}
small {
  font-size: 12px;
}
.skip-link {
  position: fixed;
  left: 12px;
  top: -100px;
  z-index: 20;
  padding: 10px;
  background: white;
}
.skip-link:focus {
  top: 10px;
}
.admin-nav {
  position: fixed;
  inset: 0 auto 0 0;
  width: 244px;
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 32px 22px;
  display: flex;
  flex-direction: column;
  z-index: 10;
}
.admin-brand {
  display: flex;
  align-items: center;
  gap: 11px;
  font-size: 15px;
  font-weight: 750;
  color: var(--deep);
  line-height: 1.3;
}
.admin-brand small {
  display: block;
  margin-top: 5px;
  font-size: 9px;
  letter-spacing: 1.7px;
  color: var(--muted);
}
.brand-monogram {
  width: 42px;
  height: 46px;
  display: grid;
  place-items: center;
  background: var(--deep);
  color: #fff;
  border-radius: 12px;
  font-family: Georgia, serif;
  font-size: 29px;
  border-bottom: 4px solid var(--brown);
}
.nav-label {
  font-size: 10px;
  letter-spacing: 1.6px;
  margin: 44px 12px 13px;
}
.admin-nav nav a {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 12px 14px;
  margin-bottom: 5px;
  border-radius: 9px;
  color: #6b7972;
  font-weight: 550;
}
.admin-nav nav a > span {
  width: 19px;
  font-size: 20px;
  line-height: 1;
  text-align: center;
}
.admin-nav nav a.active {
  background: #eaf3ed;
  color: var(--deep);
  box-shadow: inset 3px 0 var(--green);
}
.admin-nav nav a:hover {
  background: #f4f7f3;
  color: var(--deep);
}
.nav-bottom {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding: 20px 12px 0;
}
.nav-bottom > a {
  display: flex;
  justify-content: space-between;
}
.nav-bottom form {
  margin-top: 18px;
}
.nav-bottom button {
  border: 0;
  padding: 0;
  background: none;
  color: var(--brown);
}
.admin-workspace {
  margin-left: 244px;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
.admin-topbar {
  height: 88px;
  border-bottom: 1px solid var(--line);
  background: #ffffffb8;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 38px;
  gap: 16px;
}
.workspace-label {
  color: #6b7972;
  font-size: 12px;
}
.workspace-label > span {
  margin: 0 10px;
  color: #b6c1bb;
}
.admin-user {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 650;
}
.admin-user small {
  display: block;
  color: var(--muted);
  font-size: 10px;
  font-weight: 400;
}
.user-avatar {
  width: 35px;
  height: 35px;
  background: #f4e9e3;
  border-radius: 50%;
  color: var(--brown);
  display: grid;
  place-items: center;
}
.admin-main {
  padding: 36px 38px 55px;
  max-width: 1500px;
  width: 100%;
  margin: 0 auto;
  flex: 1;
  min-width: 0;
}
.admin-footer {
  display: flex;
  justify-content: space-between;
  border-top: 1px solid var(--line);
  padding: 20px 38px;
  color: #859088;
  font-size: 11px;
}
.nav-toggle {
  display: none;
}
.page-heading {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 28px;
}
.page-heading p {
  margin: 0;
  max-width: 620px;
}
.eyebrow {
  display: block;
  font-size: 10px;
  letter-spacing: 1.6px;
  color: var(--brown);
  font-weight: 700;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.btn,
.cms button.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 17px;
  border-radius: 8px;
  border: 1px solid var(--green);
  background: var(--green);
  color: white;
  font-weight: 650;
  line-height: 1.3;
  white-space: nowrap;
  transition: background 0.2s;
}
.btn:hover {
  background: #096646;
}
.btn.secondary {
  background: white;
  color: var(--ink);
  border-color: var(--line);
}
.btn.danger {
  background: #fff7f3;
  color: var(--brown);
  border-color: #ead3c7;
}
.btn.small {
  padding: 8px 12px;
  font-size: 12px;
}
.btn-row {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}
.panel {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 26px;
  margin-bottom: 22px;
  box-shadow: 0 3px 12px #14362b03;
}
.panel-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 20px;
}
.panel-heading h2 {
  margin: 0;
}
.muted {
  color: var(--muted);
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 26px;
}
.stat {
  background: white;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px;
  position: relative;
}
.stat > span {
  font-size: 12px;
  color: var(--muted);
}
.stat strong {
  display: block;
  font-size: 32px;
  letter-spacing: -1px;
  margin: 12px 0 5px;
  font-weight: 650;
}
.stat small {
  color: var(--green);
}
.stat:nth-child(even) small {
  color: var(--brown);
}
.welcome-panel {
  background: #edf3ee;
  border: 1px solid #dce7dc;
  display: flex;
  justify-content: space-between;
  gap: 25px;
}
.welcome-panel p {
  max-width: 550px;
  margin-bottom: 0;
}
.welcome-panel .eyebrow {
  color: var(--green);
}
.table-scroll {
  overflow: auto;
}
table {
  width: 100%;
  border-collapse: collapse;
  white-space: nowrap;
}
th {
  text-align: left;
  font-size: 10px;
  letter-spacing: 0.8px;
  text-transform: uppercase;
  color: #839088;
  padding: 14px;
  background: #f7f9f6;
  border-bottom: 1px solid var(--line);
}
td {
  padding: 18px 14px;
  border-bottom: 1px solid #eef1ec;
  font-size: 13px;
}
tr:last-child td {
  border-bottom: 0;
}
td .title {
  font-weight: 600;
  color: var(--ink);
  display: block;
  white-space: normal;
  min-width: 180px;
  max-width: 380px;
}
td small {
  display: block;
  color: var(--muted);
  margin-top: 4px;
}
.post-cell {
  display: flex;
  align-items: center;
  gap: 13px;
}
.thumb {
  width: 68px;
  height: 52px;
  object-fit: cover;
  border-radius: 7px;
  flex: none;
  background: #edf3ee;
}
.placeholder-thumb {
  display: grid;
  place-items: center;
  font-size: 23px;
  color: #95aa9d;
}
.badge {
  display: inline-block;
  border-radius: 30px;
  padding: 4px 10px;
  font-size: 10px;
  font-weight: 650;
  background: #f1ede6;
  color: #8c714b;
  text-transform: capitalize;
}
.badge.published,
.badge.confirmed,
.badge.completed,
.badge.contacted {
  background: #e8f3ec;
  color: #34735a;
}
.badge.cancelled,
.badge.closed {
  background: #f4e8e2;
  color: var(--brown);
}
.table-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}
.table-actions form {
  margin: 0;
}
.toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 16px;
}
.toolbar input {
  max-width: 300px;
  margin: 0;
}
.empty-state {
  text-align: center;
  padding: 40px 20px;
}
.empty-state h2 {
  font-size: 22px;
}
.empty-state p {
  max-width: 420px;
  margin: 0 auto 20px;
}
.alert {
  padding: 14px 18px;
  border-radius: 10px;
  margin-bottom: 22px;
  border: 1px solid #cfe1d4;
  background: #ecf6ee;
  color: #356b4c;
}
.alert.error {
  background: #fff1eb;
  border-color: #ecd2c8;
  color: #994933;
}
.editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  align-items: start;
}
.editor-layout .panel {
  margin: 0;
}
.editor-sidebar {
  display: grid;
  gap: 20px;
}
.editor-sidebar .panel {
  padding: 22px;
}
label {
  display: block;
  font-size: 12px;
  font-weight: 650;
  margin: 18px 0 7px;
}
label:first-child {
  margin-top: 0;
}
input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
textarea,
select {
  display: block;
  width: 100%;
  padding: 11px 13px;
  border: 1px solid #dbe3dc;
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  outline-offset: 2px;
}
textarea {
  resize: vertical;
  line-height: 1.7;
}
textarea.article-input {
  min-height: 400px;
}
input[type="file"] {
  display: block;
  width: 100%;
  font-size: 11px;
  margin-top: 10px;
}
input::file-selector-button {
  padding: 8px 10px;
  border-radius: 6px;
  background: #edf4ee;
  border: 0;
  margin-right: 8px;
  color: var(--deep);
  cursor: pointer;
}
.field-hint {
  font-size: 11px;
  margin: 8px 0 0;
  line-height: 1.6;
}
.check-label {
  display: flex;
  gap: 8px;
  align-items: center;
  font-weight: 500;
}
.check-label input {
  accent-color: var(--green);
}
.preview {
  display: block;
  width: 100%;
  height: 165px;
  object-fit: cover;
  border-radius: 9px;
  background: #f1f5ee;
  margin-top: 14px;
}
.preview[hidden] {
  display: none;
}
.upload-panel {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}
.upload-panel h2 {
  margin-bottom: 8px;
}
.upload-panel .btn {
  margin-top: 20px;
}
.media-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}
.media-item {
  padding: 0;
  overflow: hidden;
}
.media-item > img {
  width: 100%;
  height: 185px;
  object-fit: cover;
  display: block;
}
.media-content {
  padding: 18px;
}
.media-content > .panel-heading {
  margin-bottom: 10px;
}
.media-content h3 {
  margin: 0;
  font-size: 14px;
}
.media-content summary {
  cursor: pointer;
  color: var(--green);
  font-weight: 600;
  font-size: 12px;
  padding: 10px 0;
}
.media-content form {
  margin-bottom: 8px;
}
.media-content .btn-row {
  margin-top: 16px;
}
.request-list {
  display: grid;
  gap: 16px;
}
.request-item {
  margin: 0;
}
.request-summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.request-summary h2 {
  margin: 0 0 6px;
  font-size: 16px;
}
.request-summary p {
  margin: 0;
  font-size: 12px;
}
.request-item details {
  border-top: 1px solid var(--line);
  margin-top: 18px;
  padding-top: 14px;
}
.request-item summary {
  cursor: pointer;
  color: var(--green);
  font-size: 12px;
  font-weight: 600;
}
.request-fields {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
  margin: 18px 0;
}
.request-fields dt {
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--muted);
}
.request-fields dd {
  margin: 4px 0 0;
  overflow-wrap: anywhere;
}
.status-form {
  display: flex;
  gap: 8px;
  align-items: end;
  margin-top: 18px;
}
.status-form label {
  margin: 0;
  min-width: 170px;
}
.status-form select {
  margin-top: 7px;
}
.settings-form {
  max-width: 760px;
}
.settings-form .btn {
  margin-top: 24px;
}
.login-page {
  display: grid;
  grid-template-columns: 1fr 1fr;
  min-height: 100vh;
  background: #fff;
}
.login-intro {
  background: var(--deep);
  color: #fff;
  padding: 65px max(40px, 7vw);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  position: relative;
  overflow: hidden;
}
.login-intro::after {
  content: "";
  position: absolute;
  width: 380px;
  height: 380px;
  border: 1px solid #ffffff16;
  border-radius: 50%;
  right: -150px;
  bottom: -100px;
  box-shadow:
    0 0 0 60px #ffffff04,
    0 0 0 120px #ffffff03;
  pointer-events: none;
}
.login-intro .admin-brand {
  color: white;
}
.login-intro .admin-brand small {
  color: #bccfc3;
}
.login-intro .brand-monogram {
  background: #fff;
  color: var(--deep);
}
.login-intro h1 {
  font-size: clamp(30px, 4vw, 52px);
  max-width: 460px;
  line-height: 1.13;
  margin: 60px 0 20px;
}
.login-intro p {
  color: #c0d0c5;
  max-width: 400px;
}
.login-intro small {
  color: #99b2a2;
}
.login-form-wrap {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
}
.login-card {
  width: 100%;
  max-width: 380px;
}
.login-card h2 {
  font-size: 30px;
  letter-spacing: -1px;
}
.login-card .btn {
  width: 100%;
  margin-top: 26px;
}
.login-card > a {
  display: block;
  text-align: center;
  font-size: 12px;
  margin-top: 22px;
}
@media (max-width: 1150px) {
  .admin-nav {
    width: 210px;
    padding: 28px 15px;
  }
  .admin-workspace {
    margin-left: 210px;
  }
  .admin-main {
    padding: 28px;
  }
  .stats {
    grid-template-columns: repeat(2, 1fr);
  }
  .editor-layout {
    grid-template-columns: minmax(0, 1fr) 260px;
  }
  .media-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 800px) {
  .admin-nav {
    display: none;
    top: 72px;
    width: min(280px, 85vw);
    box-shadow: 15px 20px 45px #173d3325;
  }
  .nav-open .admin-nav {
    display: flex;
  }
  .admin-workspace {
    margin-left: 0;
  }
  .admin-topbar {
    height: 72px;
    padding: 0 20px;
  }
  .workspace-label {
    display: none;
  }
  .nav-toggle {
    display: flex;
    gap: 8px;
    align-items: center;
    border: 0;
    background: none;
    color: var(--deep);
    font-size: 20px;
  }
  .nav-toggle span {
    font-size: 12px;
  }
  .admin-main {
    padding: 26px 18px;
  }
  .page-heading {
    align-items: flex-start;
    flex-wrap: wrap;
  }
  .editor-layout {
    grid-template-columns: 1fr;
  }
  .editor-sidebar {
    grid-template-columns: 1fr 1fr;
  }
  .admin-footer {
    padding: 20px;
    gap: 10px;
    flex-wrap: wrap;
  }
  .login-page {
    grid-template-columns: 1fr;
  }
  .login-intro {
    padding: 28px;
  }
  .login-intro h1 {
    font-size: 28px;
    margin: 30px 0 10px;
  }
  .login-intro > small {
    display: none;
  }
  .login-form-wrap {
    padding: 32px 22px;
  }
  .request-fields {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
@media (max-width: 520px) {
  .stats {
    gap: 10px;
  }
  .stat {
    padding: 16px;
  }
  .stat strong {
    font-size: 28px;
  }
  .panel {
    padding: 20px;
  }
  .media-grid,
  .upload-panel,
  .editor-sidebar {
    grid-template-columns: 1fr;
  }
  .media-item {
    padding: 0;
  }
  .toolbar {
    align-items: stretch;
    flex-direction: column;
  }
  .toolbar input {
    max-width: none;
  }
  .request-summary {
    align-items: flex-start;
  }
  .request-fields {
    grid-template-columns: 1fr;
  }
  .welcome-panel {
    flex-direction: column;
  }
  .page-heading .btn {
    font-size: 12px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
    transition: none !important;
  }
}

.logout-trigger {
    font: inherit;
    color: inherit;
    background: transparent;
    border: 0;
    cursor: pointer;
    text-align: left;
}

#logout-modal {
    width: min(420px, calc(100% - 40px));
    box-sizing: border-box;
    padding: 30px;
    margin: auto;
    border: 0;
    border-radius: 14px;
    background: #fff;
    color: #28443a;
    box-shadow: 0 20px 60px rgb(0 0 0 / 20%);
}

#logout-modal::backdrop {
    background: rgb(0 0 0 / 45%);
}

#logout-modal h2 {
    margin: 0 0 10px;
    font-size: 1.5rem;
    color: #064438;
}

#logout-modal p {
    margin: 0;
    line-height: 1.6;
    color: #64736c;
}

#logout-modal .logout-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 26px;
}

#logout-modal form {
    margin: 0;
}

#logout-modal button {
    min-height: 44px;
    padding: 10px 20px;
    border: 1px solid #dce5df;
    border-radius: 7px;
    background: #fff;
    color: #28443a;
    font: inherit;
    font-weight: 600;
    cursor: pointer;
}

#logout-modal button[type="submit"] {
    background: #8b3f2f;
    border-color: #8b3f2f;
    color: #fff;
}

#logout-modal button[type="submit"]:hover {
    background: #713225;
}

#logout-modal button:focus-visible {
    outline: 3px solid #087a55;
    outline-offset: 3px;
}
