* {
  box-sizing: border-box;
}

:root {
  --bg: #f3f7fb;
  --surface: #ffffff;
  --surface-soft: #f8fbff;
  --text: #0f172a;
  --muted: #475569;
  --line: #d9e2ec;
  --brand: #0f766e;
  --brand-dark: #115e59;
  --accent: #0ea5e9;
  --warning: #b45309;
}

body {
  margin: 0;
  font-family: "Segoe UI", "PingFang SC", "Helvetica Neue", sans-serif;
  background: radial-gradient(circle at top right, #e3f2ff 0%, var(--bg) 40%, #eef5fb 100%);
  color: var(--text);
}

a {
  color: inherit;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

.page-space {
  padding-top: 22px;
  padding-bottom: 32px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  backdrop-filter: blur(8px);
  background: rgba(243, 247, 251, 0.92);
  border-bottom: 1px solid #dbe7f2;
}

.header-inner {
  min-height: 68px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  position: relative;
}

.brand {
  font-size: 20px;
  font-weight: 800;
  text-decoration: none;
  letter-spacing: 0.2px;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}

.main-nav a {
  text-decoration: none;
  color: #334155;
  font-weight: 700;
  font-size: 16px;
  line-height: 1;
  padding: 9px 12px;
  border-radius: 10px;
  transition: all 0.16s ease;
}

.main-nav a:hover {
  color: var(--brand-dark);
  background: #e8f3f2;
}

.main-nav a.nav-active {
  color: #ffffff;
  background: var(--brand);
  box-shadow: 0 4px 10px rgba(15, 118, 110, 0.22);
}

.mobile-nav-toggle {
  display: none;
  border: 1px solid #cdd8e3;
  background: #f8fbff;
  border-radius: 9px;
  padding: 8px 12px;
  font-weight: 700;
  font-size: 14px;
  color: #0f172a;
  cursor: pointer;
}

.header-cta {
  white-space: nowrap;
}

.hero {
  padding: 36px 0 18px;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 16px;
}

.eyebrow {
  margin: 0 0 8px 0;
  color: #0369a1;
  font-size: 13px;
  font-weight: 800;
  letter-spacing: 0.8px;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 10px 0;
  line-height: 1.28;
}

h1 {
  font-size: 34px;
}

h2 {
  font-size: 24px;
}

h3 {
  font-size: 18px;
}

h4 {
  font-size: 15px;
}

.subtitle {
  margin: 0;
  color: var(--muted);
  font-size: 15px;
}

.trust-list {
  margin: 16px 0 0;
  padding: 0 0 0 18px;
  color: #334155;
  display: grid;
  gap: 5px;
}

.highlight-card {
  background: linear-gradient(180deg, #ffffff 0%, #f2f9ff 100%);
  border: 1px solid #cfe3f3;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 12px 28px rgba(15, 118, 110, 0.1);
}

.stats-grid {
  margin-top: 8px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.stats-grid strong {
  display: block;
  font-size: 22px;
}

.stats-grid span {
  color: var(--muted);
  font-size: 13px;
}

.section {
  padding: 14px 0 20px;
}

.section.muted {
  background: linear-gradient(180deg, rgba(218, 238, 255, 0.35) 0%, rgba(218, 238, 255, 0.08) 100%);
  border-top: 1px solid #deebf7;
  border-bottom: 1px solid #deebf7;
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.section-desc {
  margin: 0 0 12px;
  color: var(--muted);
}

.ad-slot-section {
  padding-top: 0;
}

.block.ad-slot-section {
  padding: 0;
  overflow: hidden;
}

.block.ad-slot-section .ad-carousel {
  border: 0;
  border-radius: 0;
  box-shadow: none;
}

.ad-carousel {
  position: relative;
  border: 1px solid #d6e4f1;
  border-radius: 14px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 10px 24px rgba(15, 23, 42, 0.08);
}

.ad-carousel-track {
  position: relative;
  min-height: 180px;
}

.ad-slide {
  display: none;
  position: relative;
}

.ad-slide.active {
  display: block;
}

.ad-slide-link {
  display: block;
  text-decoration: none;
}

.ad-slide img {
  width: 100%;
  height: min(34vw, 220px);
  min-height: 160px;
  object-fit: cover;
  display: block;
}

.ad-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  border: 0;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  color: #ffffff;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.ad-nav.prev {
  left: 10px;
}

.ad-nav.next {
  right: 10px;
}

.ad-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 10px;
  display: flex;
  justify-content: center;
  gap: 6px;
}

.ad-dot {
  width: 8px;
  height: 8px;
  border-radius: 999px;
  border: 0;
  background: rgba(255, 255, 255, 0.56);
  cursor: pointer;
  padding: 0;
}

.ad-dot.active {
  background: #ffffff;
  width: 16px;
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.workflow-tabs {
  position: static;
  margin-bottom: 12px;
  padding: 10px;
}

.workflow-tab-list {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: thin;
}

.workflow-tab {
  border: 1px solid #d0dce7;
  background: #f8fafc;
  color: #334155;
  border-radius: 999px;
  padding: 8px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  white-space: nowrap;
}

.workflow-tab.active {
  background: #0f766e;
  border-color: #0f766e;
  color: #ffffff;
}

.workflow-panel {
  margin-bottom: 14px;
}

.generator-page {
  display: grid;
  gap: 14px;
}

.generator-page > section {
  margin: 0;
}

.generator-page .workflow-tabs,
.generator-page .workflow-panel,
.generator-page .ad-slot-section {
  margin-bottom: 0;
}

.generator-page .ad-slot-section {
  padding-top: 0;
}

.generator-page .section-gap {
  margin-top: 0;
}

.templates-page {
  display: grid;
  gap: 14px;
}

.templates-page > section {
  margin: 0;
}

.templates-page .ad-slot-section {
  padding-top: 0;
}

.templates-page .section-gap {
  margin-top: 0;
}

.articles-ad-slot {
  margin: 14px 0;
}

.block {
  background: var(--surface);
  border: 1px solid #d7e5f1;
  border-radius: 14px;
  padding: 18px;
  box-shadow: 0 10px 24px rgba(12, 74, 110, 0.08);
}

.cards,
.module-grid,
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(230px, 1fr));
  gap: 12px;
}

.card,
.module-card,
.article-card {
  background: var(--surface-soft);
  border: 1px solid #d5e4f0;
  border-radius: 12px;
  padding: 14px;
}

.article-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  height: 100%;
}

.article-card .article-read-link {
  margin-top: auto;
  align-self: flex-start;
}

.article-title-link {
  color: #0f172a;
  text-decoration: none;
}

.article-title-link:hover {
  color: #0f766e;
}

.template-card {
  display: grid;
  gap: 8px;
}

.template-page-intro {
  display: grid;
  gap: 8px;
}

.template-detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}

.template-detail-card {
  display: grid;
  gap: 12px;
  background: #f8fbff;
  border: 1px solid #cfe0ed;
  border-radius: 14px;
  padding: 14px;
}

.template-detail-head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}

.template-industry-badge {
  display: inline-flex;
  align-items: center;
  border: 1px solid #8fd4ca;
  border-radius: 999px;
  background: #e6fffa;
  color: #115e59;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 8px;
  white-space: nowrap;
}

.template-description {
  margin: 0;
  color: #475569;
  line-height: 1.6;
}

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

.template-meta-item {
  border: 1px solid #d8e7f3;
  border-radius: 10px;
  background: #ffffff;
  padding: 9px 10px;
}

.template-meta-item span {
  display: block;
  color: #64748b;
  font-size: 12px;
}

.template-meta-item strong {
  display: block;
  margin-top: 4px;
  color: #0f172a;
  font-size: 15px;
}

.template-pattern-wrap {
  display: grid;
  gap: 6px;
}

.template-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.template-chip {
  display: inline-flex;
  align-items: center;
  padding: 3px 8px;
  border: 1px solid #c1d6e8;
  border-radius: 999px;
  background: #ffffff;
  font-size: 12px;
  color: #0f4f64;
  font-weight: 700;
}

.template-best-list {
  margin: 0;
  padding-left: 18px;
  color: #334155;
  display: grid;
  gap: 4px;
}

.module-card p,
.article-card p {
  margin: 0;
  color: var(--muted);
}

.article-meta {
  font-size: 12px;
  color: #64748b;
  font-weight: 700;
  letter-spacing: 0.2px;
}

.article-tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.article-tag {
  display: inline-block;
  font-size: 12px;
  line-height: 1;
  color: #0f4f64;
  background: #e5f7ff;
  border: 1px solid #bde8ff;
  border-radius: 999px;
  padding: 5px 8px;
}

.article-pagination {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.article-page-numbers {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.article-page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 36px;
  border: 1px solid #c8d7e5;
  border-radius: 9px;
  background: #f8fbff;
  color: #0f172a;
  text-decoration: none;
  font-weight: 700;
  font-size: 13px;
  padding: 0 10px;
}

.article-page-link:hover {
  background: #eaf3ff;
}

.article-page-link.active {
  background: var(--brand);
  border-color: var(--brand);
  color: #ffffff;
}

.article-page-link.disabled {
  opacity: 0.45;
  cursor: not-allowed;
  pointer-events: none;
}

.keyword-pill {
  margin-top: 8px;
  display: inline-block;
  font-size: 12px;
  color: #0369a1;
  background: #e0f2fe;
  border: 1px solid #bae6fd;
  border-radius: 999px;
  padding: 4px 8px;
}

.form-row {
  margin-bottom: 12px;
}

.form-row label {
  display: block;
  font-weight: 700;
  margin-bottom: 5px;
}

.form-row label.checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 0;
}

.form-row label.checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
}

.form-row input,
.form-row select {
  width: 100%;
  border: 1px solid #bfd1df;
  border-radius: 9px;
  padding: 9px 10px;
  font-size: 14px;
  background: #fff;
}

.field-hint {
  margin: 6px 0 0;
  font-size: 12px;
  color: #64748b;
}

.custom-shifts-list {
  display: grid;
  gap: 8px;
}

.custom-shift-item {
  display: grid;
  grid-template-columns: 100px minmax(120px, 1fr) 88px 112px 112px 120px auto;
  gap: 8px;
  align-items: center;
  padding: 10px;
  border: 1px solid #d5e4f0;
  border-radius: 10px;
  background: #f8fbff;
}

.custom-shift-item input[type="text"],
.custom-shift-item input[type="time"],
.custom-shift-item input[type="number"] {
  width: 100%;
  border: 1px solid #bfd1df;
  border-radius: 8px;
  padding: 7px 8px;
  font-size: 13px;
  background: #fff;
}

.custom-shift-item input[type="color"] {
  width: 100%;
  height: 36px;
  border: 1px solid #bfd1df;
  border-radius: 8px;
  padding: 2px;
  background: #fff;
}

.custom-remove-wrap {
  display: flex;
  justify-content: flex-end;
}

.action-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.action-row .inline-select {
  min-width: 160px;
  border: 1px solid #c7d7e5;
  border-radius: 9px;
  padding: 9px 10px;
  font-size: 14px;
  background: #fff;
}

.month-switch-label {
  display: inline-flex;
  align-items: center;
  padding: 0 6px;
  font-weight: 700;
  color: #334155;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #d0dce7;
  border-radius: 9px;
  padding: 9px 14px;
  background: #f1f5f9;
  color: #111827;
  text-decoration: none;
  cursor: pointer;
  font-weight: 700;
  font-size: 14px;
  transition: all 0.15s ease;
}

.btn:hover {
  background: #e2e8f0;
}

.btn:active,
.btn.is-active,
.btn.is-busy {
  background: var(--brand);
  border-color: var(--brand);
  color: #ffffff;
}

.btn.primary {
  background: var(--brand);
  border-color: var(--brand);
  color: #fff;
}

.btn.primary:hover {
  background: var(--brand-dark);
}

.btn.small {
  width: fit-content;
  padding: 7px 12px;
  font-size: 13px;
}

.btn[disabled] {
  opacity: 0.75;
  cursor: not-allowed;
}

.text-link {
  color: #0369a1;
  text-decoration: none;
  font-weight: 700;
}

.text-link:hover {
  text-decoration: underline;
}

.hint {
  margin: 10px 0 0;
  color: #0f766e;
  font-size: 14px;
}

.warning-text {
  color: var(--warning);
}

.shift-pill {
  display: inline-block;
  border: 1px solid #94a3b8;
  border-radius: 999px;
  padding: 2px 8px;
  font-size: 12px;
  font-weight: 700;
  background: #f8fafc;
}

.summary-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 12px;
}

.summary-card {
  border: 1px solid #cfe0ed;
  border-radius: 10px;
  padding: 10px;
  background: #f8fbff;
}

.summary-card span {
  display: block;
  color: #64748b;
  font-size: 12px;
  margin-bottom: 3px;
}

.summary-card strong {
  font-size: 16px;
}

.empty-state {
  border: 1px dashed #b9cfdf;
  border-radius: 12px;
  padding: 18px;
  color: #64748b;
  text-align: center;
  background: #f8fcff;
}

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

.hidden {
  display: none !important;
}

.calendar-wrap {
  margin-top: 14px;
}

.calendar-grid-toolbar {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}

.calendar-month {
  margin-bottom: 18px;
}

.calendar-month h3 {
  margin: 0 0 8px 0;
}

.calendar-table,
.week-table {
  width: 100%;
  border-collapse: collapse;
}

.calendar-table th,
.calendar-table td,
.week-table th,
.week-table td {
  border: 1px solid #d1d9e4;
  padding: 7px;
  vertical-align: top;
}

.week-table th {
  background: #f3f8fd;
}

.calendar-table td {
  height: 92px;
  width: 14.28%;
}

.calendar-table td.empty {
  background: #f8fafc;
  color: #94a3b8;
}

.calendar-table td.empty .day-num {
  color: #94a3b8;
  font-weight: 700;
}

.calendar-table td.empty .holiday-tag,
.calendar-table td.empty .shift-code,
.calendar-table td.empty .shift-hours {
  color: #cbd5e1;
}

.calendar-table td.holiday {
  background: #fff8eb;
}

.day-num {
  font-weight: 800;
}

.shift-code {
  margin-top: 4px;
  font-size: 13px;
}

.shift-hours {
  color: #334155;
  font-size: 12px;
}

.holiday-tag {
  margin-top: 4px;
  color: #9a3412;
  font-size: 11px;
}

.share-box {
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid #d7e5f1;
}

.share-qr-wrap {
  margin-top: 10px;
  padding: 10px;
  border: 1px solid #d7e5f1;
  border-radius: 10px;
  background: #f8fbff;
  width: fit-content;
}

.share-qr-wrap img {
  width: 180px;
  height: 180px;
  display: block;
}

.display-toggle-row {
  margin: 10px 0 14px;
  border: 1px solid #9fd3cc;
  background: linear-gradient(180deg, #f3fffd 0%, #e8f8f5 100%);
  border-radius: 12px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.advanced-holiday-filters {
  margin: -4px 0 14px;
  border: 1px dashed #b8d6cf;
  border-radius: 12px;
  background: #f8fffd;
  padding: 10px 12px;
}

.advanced-holiday-filters summary {
  cursor: pointer;
  color: #115e59;
  font-weight: 600;
  font-size: 13px;
}

.advanced-holiday-filters .field-hint {
  margin: 8px 0 0;
}

.advanced-filter-grid {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px 12px;
}

.advanced-filter-grid .checkbox-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  font-size: 13px;
}

.advanced-filter-grid .checkbox-row input[type="checkbox"] {
  width: 16px;
  height: 16px;
}

.display-toggle-text strong {
  display: block;
  color: #115e59;
  font-size: 14px;
}

.display-toggle-text p {
  margin: 4px 0 0;
  color: #475569;
  font-size: 12px;
}

.switch-control {
  position: relative;
  display: inline-flex;
  width: 56px;
  height: 32px;
}

.switch-control input {
  opacity: 0;
  width: 0;
  height: 0;
}

.switch-slider {
  position: absolute;
  inset: 0;
  border-radius: 999px;
  background: #cbd5e1;
  border: 1px solid #94a3b8;
  transition: all 0.2s ease;
}

.switch-slider::before {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  left: 3px;
  top: 3px;
  border-radius: 50%;
  background: #ffffff;
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.25);
  transition: transform 0.2s ease;
}

.switch-control input:checked + .switch-slider {
  background: #0f766e;
  border-color: #0f766e;
}

.switch-control input:checked + .switch-slider::before {
  transform: translateX(24px);
}

.site-footer {
  margin-top: 20px;
  border-top: 1px solid #d7e6f3;
  background: #ecf4fb;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 16px;
  padding-top: 22px;
  padding-bottom: 22px;
}

.footer-grid p,
.footer-grid a {
  margin: 0 0 8px;
  color: #334155;
  text-decoration: none;
  display: block;
}

.footer-grid a:hover {
  color: #0f766e;
}

.article-layout {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 16px;
}

.article-subtitle {
  margin-bottom: 10px;
}

.article-content {
  margin-top: 14px;
}

.rich-content {
  color: #1e293b;
  line-height: 1.8;
  font-size: 16px;
}

.rich-content h2,
.rich-content h3,
.rich-content h4 {
  margin-top: 22px;
  margin-bottom: 10px;
  color: #0f172a;
}

.rich-content p {
  margin: 0 0 14px;
}

.rich-content ul,
.rich-content ol {
  margin: 0 0 14px 20px;
}

.rich-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 8px 0 14px;
}

.rich-content th,
.rich-content td {
  border: 1px solid #d2ddea;
  padding: 8px 10px;
}

.rich-content blockquote {
  margin: 12px 0;
  padding: 10px 12px;
  border-left: 4px solid #0ea5e9;
  background: #f0f9ff;
  color: #0c4a6e;
}

.article-cta-box {
  border-top: 1px dashed #c6d9ea;
  padding-top: 12px;
}

.article-side .related-list {
  display: grid;
  gap: 12px;
}

.related-item {
  border: 1px solid #d2e2ee;
  border-radius: 10px;
  padding: 10px;
  text-decoration: none;
  background: #f7fbff;
}

.related-item strong {
  display: block;
  margin-bottom: 6px;
  color: #0f172a;
  font-size: 14px;
}

.related-item span {
  color: #64748b;
  font-size: 12px;
  display: block;
}

.related-item p {
  margin: 8px 0;
  color: #475569;
  font-size: 13px;
  line-height: 1.5;
}

.section-gap {
  margin-top: 14px;
}

.calendar-snapshot-banner {
  margin-top: 12px;
  border: 1px solid #c5deef;
  border-radius: 10px;
  padding: 12px;
  background: #f4fbff;
}

.calendar-snapshot-banner p {
  margin: 6px 0 0;
  color: #475569;
}

.feedback-float-btn {
  position: fixed;
  right: 18px;
  bottom: 18px;
  z-index: 66;
  border: 1px solid #0f766e;
  background: #0f766e;
  color: #fff;
  border-radius: 999px;
  padding: 10px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  box-shadow: 0 10px 26px rgba(15, 118, 110, 0.28);
}

.feedback-panel {
  position: fixed;
  right: 18px;
  bottom: 68px;
  z-index: 67;
  width: min(350px, calc(100vw - 24px));
  border: 1px solid #cfe0ed;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 16px 36px rgba(14, 63, 99, 0.25);
  padding: 12px;
}

.feedback-panel h3 {
  margin: 0 0 4px;
}

.feedback-panel p {
  margin: 0 0 8px;
  color: #64748b;
  font-size: 13px;
}

.feedback-panel input,
.feedback-panel textarea {
  width: 100%;
  border: 1px solid #bfd1df;
  border-radius: 8px;
  padding: 8px 9px;
  font-size: 14px;
  margin-bottom: 8px;
}

.feedback-panel textarea {
  resize: vertical;
}

.feedback-actions {
  display: flex;
  gap: 8px;
}

.admin-login-page {
  min-height: 100vh;
  background: radial-gradient(circle at top, #dbeafe 0%, #eaf3fb 42%, #f8fbff 100%);
}

.admin-login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.admin-login-shell {
  width: min(980px, 100%);
  display: grid;
  grid-template-columns: 1.05fr 0.95fr;
  border: 1px solid #d7e6f3;
  border-radius: 16px;
  overflow: hidden;
  background: #ffffff;
  box-shadow: 0 24px 48px rgba(15, 23, 42, 0.14);
}

.admin-login-hero {
  background: linear-gradient(160deg, #0f766e 0%, #0ea5e9 100%);
  color: #ecfeff;
  padding: 28px 24px;
}

.admin-login-tag {
  margin: 0 0 10px;
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.6px;
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.36);
}

.admin-login-hero h1 {
  margin-bottom: 8px;
  font-size: 30px;
}

.admin-login-hero p {
  margin: 0 0 12px;
  color: rgba(236, 254, 255, 0.95);
}

.admin-login-hero ul {
  margin: 0;
  padding-left: 18px;
  display: grid;
  gap: 6px;
  color: rgba(236, 254, 255, 0.95);
}

.admin-login-card {
  width: 100%;
  background: #ffffff;
  padding: 24px 20px;
}

.admin-login-card h2 {
  margin-bottom: 4px;
}

.admin-login-card .layui-form-label {
  width: 64px;
  padding-left: 0;
}

.admin-login-card .layui-input-block {
  margin-left: 80px;
}

.admin-login-hint {
  margin-top: 12px;
  color: #475569;
  font-size: 13px;
}

.admin-console-page {
  background: #f1f5f9;
}

.admin-main {
  padding: 14px;
}

.admin-panel {
  display: none;
  background: #fff;
  border: 1px solid #d9e3ef;
  border-radius: 10px;
  padding: 14px;
  margin-bottom: 12px;
}

.admin-panel.active {
  display: block;
}

.admin-kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-bottom: 12px;
}

.admin-kpi-card {
  border: 1px solid #d9e3ef;
  border-radius: 10px;
  padding: 10px;
  background: #f8fbff;
}

.admin-kpi-card span {
  color: #64748b;
  font-size: 12px;
}

.admin-kpi-card strong {
  display: block;
  margin-top: 4px;
  font-size: 24px;
}

.admin-chart-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-bottom: 12px;
}

.admin-chart-box {
  width: 100%;
  height: 300px;
}

.admin-cell-text {
  max-width: 460px;
  overflow-wrap: anywhere;
  white-space: normal;
}

.admin-action-cell {
  white-space: normal;
  min-width: 130px;
}

.admin-action-cell .layui-btn {
  margin: 0 4px 4px 0;
}

.admin-dialog-wrap {
  padding: 12px;
}

.feedback-dialog-scroll {
  height: 100%;
  overflow-y: auto;
}

.admin-dialog-gap {
  margin-top: 10px;
}

.admin-dialog-label {
  display: block;
  margin-bottom: 6px;
  font-weight: 700;
}

.admin-dialog-info {
  margin-bottom: 6px;
  color: #334155;
}

.admin-dialog-content {
  margin-bottom: 10px;
  border: 1px solid #d5e4f0;
  border-radius: 8px;
  padding: 8px;
  background: #f8fbff;
  color: #0f172a;
  white-space: pre-wrap;
}

.admin-article-editor {
  height: 100%;
  overflow-y: auto;
  padding: 12px;
}

.article-rich-editor {
  border: 1px solid #d5e4f0;
  border-radius: 8px;
  overflow: hidden;
  background: #ffffff;
}

.article-rich-editor .ql-toolbar.ql-snow {
  border: 0;
  border-bottom: 1px solid #d5e4f0;
}

.article-rich-editor .ql-container.ql-snow {
  border: 0;
  min-height: 520px;
  font-size: 15px;
}

.article-rich-fallback {
  display: none;
  margin-top: 8px;
}

.admin-pagination {
  margin-top: 10px;
  text-align: right;
}

.admin-ad-thumb {
  width: 100px;
  height: 56px;
  object-fit: cover;
  border: 1px solid #d5e4f0;
  border-radius: 6px;
  display: block;
}

.admin-ad-form-grid {
  display: grid;
  gap: 10px;
}

.admin-ad-upload-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  align-items: center;
}

.auto-publish-topic-area {
  font-family: Consolas, "Courier New", monospace;
  line-height: 1.5;
}

.auto-publish-hint {
  margin: 8px 0 0;
  color: #64748b;
  font-size: 12px;
}

@media (max-width: 980px) {
  h1 {
    font-size: 30px;
  }

  .hero-grid,
  .grid-2,
  .article-layout,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .template-detail-grid,
  .template-meta-grid {
    grid-template-columns: 1fr;
  }

  .mobile-nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .header-cta {
    display: none;
  }

  .main-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: #ffffff;
    border: 1px solid #d3dfeb;
    border-radius: 12px;
    padding: 10px 14px;
    box-shadow: 0 10px 28px rgba(14, 50, 82, 0.15);
    flex-direction: column;
    align-items: stretch;
    gap: 2px;
  }

  body.nav-open .main-nav {
    display: flex;
  }

  .main-nav a {
    font-size: 17px;
    padding: 9px 4px;
    border-bottom: 1px solid #edf2f7;
    border-radius: 8px;
  }

  .main-nav a:last-child {
    border-bottom: 0;
  }

  .main-nav a.nav-active {
    background: #0f766e;
    color: #ffffff;
    border-color: #0f766e;
  }

  .article-pagination {
    flex-direction: column;
    align-items: stretch;
  }

  .article-page-link {
    min-width: 44px;
  }

  .btn {
    min-height: 42px;
    padding: 10px 14px;
  }

  .workflow-tabs {
    padding: 8px;
  }

  .workflow-tab {
    font-size: 12px;
    padding: 8px 12px;
  }

  .custom-shift-item {
    grid-template-columns: 1fr 1fr;
  }

  .display-toggle-row {
    align-items: flex-start;
    flex-direction: column;
  }

  .advanced-filter-grid {
    grid-template-columns: 1fr;
  }

  .admin-kpi-grid {
    grid-template-columns: 1fr 1fr;
  }

  .admin-chart-grid {
    grid-template-columns: 1fr;
  }

  .admin-chart-box {
    height: 240px;
  }

  .ad-slide img {
    height: 180px;
  }

  .ad-nav {
    width: 30px;
    height: 30px;
    font-size: 18px;
  }

  .custom-remove-wrap {
    grid-column: 1 / -1;
  }

  .admin-login-wrap {
    padding: 14px;
  }

  .admin-login-shell {
    grid-template-columns: 1fr;
  }

  .admin-login-hero {
    padding: 20px 16px;
  }

  .admin-login-hero h1 {
    font-size: 26px;
  }

  .admin-login-card {
    padding: 18px 14px;
  }

  .admin-login-card .layui-form-label {
    width: 100%;
    margin-bottom: 4px;
    text-align: left;
  }

  .admin-login-card .layui-input-block {
    margin-left: 0;
  }

  .preview-page .action-row,
  .calendar-page .action-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
  }

  .preview-page .action-row .btn,
  .preview-page .action-row .inline-select,
  .calendar-page .action-row .btn,
  .calendar-page .action-row .inline-select {
    width: 100%;
    min-width: 0;
  }

  .preview-page #preview-calendar,
  .calendar-page #calendar-grid-content {
    overflow-x: auto;
  }

  .preview-page .calendar-table,
  .calendar-page .calendar-table {
    table-layout: fixed;
  }

  .preview-page .calendar-table th,
  .preview-page .calendar-table td,
  .calendar-page .calendar-table th,
  .calendar-page .calendar-table td {
    padding: 5px;
    font-size: 12px;
  }

  .preview-page .calendar-table td,
  .calendar-page .calendar-table td {
    height: 78px;
  }

  .preview-page .shift-code,
  .calendar-page .shift-code {
    font-size: 11px;
    line-height: 1.2;
    word-break: break-word;
  }

  .preview-page .holiday-tag,
  .calendar-page .holiday-tag {
    font-size: 10px;
    line-height: 1.2;
    word-break: break-word;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
  }

  .calendar-page .calendar-grid-toolbar {
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 6px;
  }

  .calendar-page .month-switch-label {
    order: -1;
    flex: 1 1 100%;
    text-align: center;
    padding: 2px 0;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 12px;
  }

  .page-space {
    padding-top: 14px;
    padding-bottom: 20px;
  }

  .block {
    padding: 14px;
    border-radius: 12px;
  }

  .generator-page .workflow-tabs {
    padding: 8px;
  }

  .generator-page .workflow-tab-list {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
    overflow: visible;
  }

  .generator-page .workflow-tab {
    min-height: 52px;
    white-space: normal;
    text-align: center;
    line-height: 1.25;
    padding: 8px 6px;
    border-radius: 10px;
  }

  .generator-page .action-row {
    display: grid;
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .generator-page .action-row .btn,
  .generator-page .action-row .inline-select {
    width: 100%;
    min-width: 0;
  }

  .generator-page .summary-grid {
    grid-template-columns: 1fr;
  }

  .generator-page .custom-shift-item {
    grid-template-columns: 1fr;
  }

  .generator-page .custom-remove-wrap {
    grid-column: auto;
    justify-content: flex-start;
  }

  .generator-page .calendar-table th,
  .generator-page .calendar-table td {
    padding: 5px;
  }

  .generator-page .calendar-table td {
    height: 78px;
  }

  .generator-page .holiday-tag {
    font-size: 10px;
    line-height: 1.2;
  }

  .preview-page .action-row,
  .calendar-page .action-row {
    grid-template-columns: 1fr;
  }

  .preview-page .calendar-table td,
  .calendar-page .calendar-table td {
    height: 70px;
  }

  .preview-page #preview-calendar .week-table,
  .calendar-page .week-table {
    min-width: 620px;
  }
}

@media print {
  body {
    background: #fff;
  }

  .site-header,
  .site-footer,
  .workflow-tabs,
  .display-toggle-row,
  .advanced-holiday-filters,
  .btn,
  .action-row,
  .inline-select,
  .feedback-float-btn,
  .feedback-modal-mask,
  .hint {
    display: none !important;
  }

  .block {
    box-shadow: none;
    border: none;
    padding: 0;
  }

  .container {
    max-width: none;
    padding: 0;
  }
}
