@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Source+Serif+4:wght@400;600;700&display=swap');

:root {
  --bg: #0b1220;
  --bg-soft: #111a2e;
  --surface: #151f36;
  --surface-2: #1e2a45;
  --text: #f8fafc;
  --text-soft: #cbd5f5;
  --accent: #fbbf24;
  --accent-2: #38bdf8;
  --success: #22c55e;
  --danger: #ef4444;
  --shadow: 0 24px 60px rgba(2, 6, 23, 0.45);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: 'Space Grotesk', system-ui, sans-serif;
  color: var(--text);
  background: radial-gradient(circle at top, rgba(56, 189, 248, 0.2), transparent 35%),
    radial-gradient(circle at 20% 40%, rgba(251, 191, 36, 0.2), transparent 40%),
    var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

.container {
  width: min(1200px, 92vw);
  margin: 0 auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: rgba(10, 15, 30, 0.85);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 0 12px;
  gap: 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.logo {
  width: 86px;
  height: 86px;
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.14);
  border-radius: 16px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.brand-name {
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.brand-tagline {
  display: block;
  font-size: 13px;
  color: var(--text-soft);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.search {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--surface);
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.2);
}

.search input {
  background: transparent;
  border: none;
  color: var(--text);
  outline: none;
  width: 190px;
}

.search button {
  border: none;
  background: var(--accent);
  color: #0b1220;
  font-weight: 600;
  padding: 6px 12px;
  border-radius: 999px;
  cursor: pointer;
}

.menu-toggle {
  display: none;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: var(--surface);
  color: var(--text);
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
}

.nav {
  background: var(--surface-2);
  border-top: 1px solid rgba(148, 163, 184, 0.1);
  border-bottom: 1px solid rgba(148, 163, 184, 0.1);
}

.nav-list {
  display: flex;
  gap: 18px;
  padding: 12px 0;
  flex-wrap: wrap;
}

.nav a {
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.6);
  color: var(--text-soft);
  font-size: 14px;
  transition: all 0.2s ease;
}

.nav a.active,
.nav a:hover {
  background: var(--accent);
  color: #0b1220;
}

.nav-item-dropdown {
  position: relative;
}

.nav-dropdown-toggle {
  padding: 6px 14px;
  border-radius: 999px;
  border: none;
  background: #eef3f9;
  color: #235185;
  font-size: 14px;
  cursor: pointer;
  font-family: inherit;
}

.nav-dropdown-toggle.active,
.nav-dropdown-toggle:hover {
  background: #c45048;
  color: #ffffff;
}

.nav-dropdown-menu {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 280px;
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.18);
  border-radius: 12px;
  padding: 8px;
  box-shadow: 0 12px 22px rgba(35, 81, 133, 0.14);
  display: none;
  z-index: 60;
}

.nav-item-dropdown:hover .nav-dropdown-menu,
.nav-item-dropdown.open .nav-dropdown-menu {
  display: block;
}

.nav-dropdown-menu a {
  display: block;
  border-radius: 8px;
  padding: 8px 10px;
  margin: 2px 0;
  background: transparent;
  color: #235185;
}

.nav-dropdown-menu a:hover {
  background: #eaf2fb;
  color: #173b63;
}

.site-main {
  padding: 28px 0 60px;
}

.hero {
  padding-top: 10px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr);
  gap: 24px;
  align-items: stretch;
}

.card {
  background: var(--surface);
  border-radius: 20px;
  overflow: hidden;
  box-shadow: var(--shadow);
  display: flex;
  flex-direction: column;
  min-height: 100%;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 24px 70px rgba(2, 6, 23, 0.6);
}

.card-media {
  min-height: 220px;
  background-size: cover;
  background-position: center;
}

.hero-card .card-media {
  min-height: 340px;
}

.card-body {
  padding: 20px;
}

.card-body p {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.hero-card .card-body h2 {
  min-height: 68px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.tag {
  display: inline-flex;
  width: fit-content;
  align-self: flex-start;
  white-space: nowrap;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  background: #235185;
  color: #ffffff;
  padding: 4px 10px;
  border-radius: 999px;
  margin-bottom: 10px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.18);
  transition: background 0.2s ease, color 0.2s ease;
}

.tag:hover,
.card:hover .tag {
  background: #c45048;
  color: #ffffff;
}

.card h2,
.card h3 {
  margin: 0 0 10px;
}

.card p {
  margin: 0 0 12px;
  color: var(--text-soft);
}

.meta {
  font-size: 13px;
  color: rgba(226, 232, 240, 0.75);
}

.hero-side {
  display: grid;
  gap: 18px;
}

.hero-main,
.hero-main .hero-card {
  height: 100%;
}

.hero-side-block {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  grid-template-rows: repeat(2, minmax(0, 1fr));
  gap: 14px;
  min-height: 100%;
}

.hero-mini-card .card-media {
  min-height: 132px;
}

.hero-mini-card .card-body {
  padding: 14px;
  display: flex;
  flex-direction: column;
  min-height: 150px;
}

.hero-mini-card h3 {
  margin: 4px 0 8px;
  font-size: 16px;
  line-height: 1.3;
  min-height: 42px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.section {
  margin-top: 40px;
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 18px;
}

.section-header h2 {
  margin: 0;
  font-size: 26px;
}

.section-header span {
  color: var(--text-soft);
}

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}

.news-card .card-media {
  min-height: 180px;
}

.article {
  margin-top: 20px;
}

.article-grid {
  display: grid;
  grid-template-columns: 2.2fr 1fr;
  gap: 24px;
}

.article-header h1 {
  font-family: 'Source Serif 4', serif;
  font-size: 36px;
  margin: 10px 0 12px;
}

.article-media {
  width: 100%;
  min-height: 360px;
  border-radius: 20px;
  background-size: cover;
  background-position: center;
  margin: 18px 0;
}

.article-content {
  font-family: 'Source Serif 4', serif;
  font-size: 18px;
  line-height: 1.7;
  color: #1f3349;
}

.article-content * {
  color: #1f3349 !important;
}

.article-content a,
.article-content a * {
  color: #235185 !important;
}

.article-content h1,
.article-content h2,
.article-content h3,
.article-content h4 {
  color: #173b63 !important;
}

.sidebar-card {
  background: var(--surface);
  padding: 20px;
  border-radius: 18px;
  margin-bottom: 20px;
}

.sidebar-card h3 {
  margin-top: 0;
}

.sidebar-card ul {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 10px;
}

.sidebar-card a {
  color: var(--text-soft);
}

.sidebar-news-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.sidebar-news-item {
  display: grid;
  grid-template-columns: 94px minmax(0, 1fr);
  gap: 10px;
  align-items: stretch;
  border: 1px solid rgba(35, 81, 133, 0.16);
  border-radius: 12px;
  overflow: hidden;
  background: #f8fbff;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
}

.sidebar-news-item:hover {
  transform: translateY(-1px);
  box-shadow: 0 10px 22px rgba(35, 81, 133, 0.16);
  border-color: rgba(196, 80, 72, 0.4);
}

.sidebar-news-thumb {
  background-size: cover;
  background-position: center;
  min-height: 76px;
}

.sidebar-news-text {
  padding: 8px 10px 8px 0;
  font-size: 13px;
  line-height: 1.35;
  color: #1f3f64;
  font-weight: 600;
}

.article-share {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin: 10px 0 14px;
}

.share-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 34px;
  padding: 0 14px;
  border-radius: 999px;
  color: #ffffff;
  font-size: 13px;
  font-weight: 700;
}

.share-whatsapp {
  background: #25d366;
}

.share-facebook {
  background: #1877f2;
}

.share-x {
  background: #111111;
}

.share-btn:hover {
  filter: brightness(0.9);
}

.newsletter input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: var(--surface-2);
  color: var(--text);
  margin-bottom: 10px;
}

.newsletter button {
  width: 100%;
  padding: 10px;
  border: none;
  border-radius: 10px;
  background: var(--accent);
  font-weight: 600;
  cursor: pointer;
}

.site-footer {
  background: #0a1020;
  padding: 40px 0 20px;
  border-top: 1px solid rgba(148, 163, 184, 0.1);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
}

.footer-logo {
  width: 86px;
  height: 86px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.4);
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  margin-bottom: 10px;
}

.footer-logo img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.footer-bottom {
  margin-top: 20px;
  padding-top: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.15);
  color: var(--text-soft);
  font-size: 13px;
}

.empty {
  padding: 30px;
  text-align: center;
  background: rgba(15, 23, 42, 0.6);
  border-radius: 16px;
  margin-top: 20px;
}

.alert {
  padding: 12px 16px;
  border-radius: 10px;
  margin-bottom: 16px;
}

.alert.error {
  background: rgba(239, 68, 68, 0.2);
  color: #fecaca;
}

.alert.success {
  background: rgba(34, 197, 94, 0.2);
  color: #bbf7d0;
}

.auth {
  max-width: 420px;
}

.auth-form,
.admin-form {
  display: grid;
  gap: 14px;
}

.auth-form label,
.admin-form label {
  display: grid;
  gap: 8px;
  color: var(--text-soft);
}

.auth-form input,
.admin-form input,
.admin-form select,
.admin-form textarea {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid rgba(148, 163, 184, 0.2);
  background: var(--surface-2);
  color: var(--text);
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 10px;
  background: var(--accent);
  color: #0b1220;
  font-weight: 600;
  border: none;
  cursor: pointer;
}

.btn.secondary {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid rgba(148, 163, 184, 0.2);
}

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

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

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 16px;
}

.form-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  margin-top: 10px;
}

.form-actions-inline {
  justify-content: flex-end;
}

.check-row-inline {
  margin-right: 8px;
}

.check {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.table {
  display: grid;
  gap: 12px;
}

.table-head,
.table-row {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 0.6fr;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.6);
}

.table-head {
  font-weight: 600;
  background: rgba(30, 41, 59, 0.8);
}

.admin-shell .container {
  max-width: 1260px;
}

.admin-stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 20px;
}

.stat-card {
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(30, 41, 59, 0.95), rgba(21, 31, 54, 0.92));
  border: 1px solid rgba(148, 163, 184, 0.18);
  padding: 16px;
}

.stat-card h3 {
  margin: 0;
  font-size: 13px;
  color: var(--text-soft);
  font-weight: 500;
}

.stat-card strong {
  display: block;
  margin-top: 8px;
  font-size: 28px;
}

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

.table-row-5,
.table-head {
  min-width: 880px;
}

.table-row-5 {
  grid-template-columns: 2fr 1fr 0.9fr 1fr 0.6fr;
}

.table-link {
  color: #7dd3fc;
  font-weight: 600;
}

.form-grid-wide {
  grid-template-columns: repeat(2, minmax(280px, 1fr));
}

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

.check-row {
  display: flex;
  gap: 14px;
  flex-wrap: wrap;
}

.admin-form textarea {
  width: 100%;
}

.quill-editor {
  background: var(--surface-2);
  border: 1px solid rgba(148, 163, 184, 0.2);
  border-radius: 10px;
  overflow: hidden;
}

.quill-editor .ql-toolbar.ql-snow {
  border: none;
  border-bottom: 1px solid rgba(148, 163, 184, 0.2);
  background: rgba(15, 23, 42, 0.5);
}

.quill-editor .ql-container.ql-snow {
  border: none;
  min-height: 420px;
  font-family: 'Source Serif 4', serif;
  font-size: 18px;
  color: var(--text);
}

.quill-editor .ql-editor {
  min-height: 420px;
}

.ql-snow .ql-picker {
  color: var(--text-soft);
}

.ql-snow .ql-stroke {
  stroke: var(--text-soft);
}

.ql-snow .ql-fill {
  fill: var(--text-soft);
}

.ql-snow .ql-picker-options {
  background: var(--surface);
  border-color: rgba(148, 163, 184, 0.25);
}

.ql-snow .ql-uploadVideo::after {
  content: 'UP';
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.4px;
}

/* Home visual refresh */
:root {
  --bg: #ffffff;
  --bg-soft: #eef3f8;
  --surface: #ffffff;
  --surface-2: #f4f7fb;
  --text: #1c2f46;
  --text-soft: #5f7388;
  --accent: #235185;
  --accent-2: #c45048;
  --shadow: 0 16px 36px rgba(35, 81, 133, 0.12);
  --header-fixed-height: 228px;
}

body {
  color: var(--text);
  background:
    radial-gradient(circle at 0% 0%, rgba(35, 81, 133, 0.14), transparent 30%),
    radial-gradient(circle at 100% 0%, rgba(196, 80, 72, 0.1), transparent 35%),
    #ffffff;
}

.site-header {
  position: relative;
  top: auto;
  left: auto;
  right: auto;
  z-index: 30;
  border-bottom: 1px solid rgba(35, 81, 133, 0.2);
  overflow: hidden;
}

.site-header::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: var(--header-bg-height, 220px);
  background-image: url('/assets/img/fundohen.png');
  background-size: 100% 100%;
  background-position: center top;
  background-repeat: no-repeat;
  z-index: 0;
}

.brand-name {
  color: var(--accent);
}

.header-row {
  position: relative;
  height: var(--header-bg-height, 220px);
  padding: 0;
  justify-content: flex-end;
  align-items: flex-end;
  width: 100%;
  max-width: 100%;
  z-index: 1;
}

.header-home-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
}

.logo {
  background: transparent;
  border: none;
  box-shadow: none;
}

.brand {
  display: none;
}

.search {
  background: transparent;
  border-color: rgba(255, 255, 255, 0.6);
}

.search input {
  color: #ffffff;
}

.search input::placeholder {
  color: rgba(255, 255, 255, 0.78);
}

.search button {
  background: var(--accent-2);
  color: #ffffff;
}

.menu-toggle {
  background: #f3f7fc;
  color: var(--accent);
  border-color: rgba(35, 81, 133, 0.16);
}

.header-actions {
  position: relative;
  z-index: 2;
  margin-bottom: 10px;
}

.nav {
  background: rgba(255, 255, 255, 0.97);
  border-top-color: rgba(35, 81, 133, 0.14);
  border-bottom-color: rgba(35, 81, 133, 0.14);
}

.nav-list {
  align-items: center;
}

.nav a {
  background: #eef3f9;
  color: #235185;
}

.nav a.active,
.nav a:hover {
  background: #c45048;
  color: #ffffff;
}

.nav-search {
  margin-left: auto;
  padding: 6px 10px;
  border-color: rgba(35, 81, 133, 0.22);
}

.nav-search input {
  color: #1c2f46;
  width: 180px;
}

.nav-search input::placeholder {
  color: #6f8194;
}

.card {
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.12);
  box-shadow: var(--shadow);
}

.card:hover {
  box-shadow: 0 20px 44px rgba(35, 81, 133, 0.2);
}

.card p,
.section-header span,
.brand-tagline {
  color: var(--text-soft);
}

.meta {
  color: #6f8194;
}

.home-layout {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(0, 1fr);
  gap: 24px;
  align-items: start;
}

.news-feed {
  display: grid;
  gap: 14px;
}

.news-item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 14px;
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.14);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 26px rgba(35, 81, 133, 0.09);
}

.news-item-media {
  min-height: 150px;
  background-size: cover;
  background-position: center;
}

.news-item-body {
  padding: 14px;
}

.news-item h3 {
  margin: 6px 0 8px;
  font-size: 20px;
}

.news-item p {
  margin: 0 0 10px;
}

.section-spaced {
  margin-top: 26px;
}

.category-title-card {
  display: inline-block;
  padding: 8px 14px;
  border-radius: 12px;
  background: #c45048;
  color: #ffffff;
}

.embed-placeholder {
  background: #edf3fb;
  color: #3a5d84;
  border-radius: 10px;
  border: 1px dashed rgba(35, 81, 133, 0.35);
  padding: 16px;
  font-size: 14px;
}

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

.quick-card {
  background: linear-gradient(140deg, rgba(35, 81, 133, 0.95), rgba(31, 69, 113, 0.92));
  color: #ffffff;
  border-radius: 14px;
  padding: 14px;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.quick-card h3 {
  margin: 0 0 8px;
  font-size: 14px;
}

.quick-card p {
  margin: 0;
  font-size: 13px;
  opacity: 0.92;
  overflow-wrap: anywhere;
}

.settings-form {
  max-width: 760px;
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.14);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 8px 24px rgba(35, 81, 133, 0.08);
}

.embed-help {
  margin-top: 14px;
  background: #f4f8fd;
  border: 1px solid rgba(35, 81, 133, 0.12);
  border-radius: 14px;
  padding: 14px;
}

.embed-help h3 {
  margin: 0 0 8px;
  color: var(--accent);
}

.embed-help p {
  margin: 4px 0;
  color: var(--text-soft);
}

.admin-page {
  background: linear-gradient(160deg, #eef4fb, #f7f9fc);
  min-height: 100vh;
}

.admin-main {
  padding: 22px 0 40px;
}

.table-row-6,
.table-head.table-row-6 {
  min-width: 980px;
  grid-template-columns: 0.8fr 2fr 1fr 0.9fr 1fr 1fr;
}

.table-row-7,
.table-head.table-row-7 {
  min-width: 1120px;
  grid-template-columns: 0.8fr 1.8fr 1fr 1.2fr 0.9fr 1fr 1fr;
}

.table-row-8,
.table-head.table-row-8 {
  min-width: 1260px;
  grid-template-columns: 0.75fr 1.55fr 1fr 1.1fr 0.8fr 0.8fr 0.42fr 1.7fr;
}

.thumb-mini {
  width: 64px;
  height: 44px;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid rgba(35, 81, 133, 0.2);
}

.thumb-icon {
  width: 64px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.8px;
  color: #ffffff;
  background: linear-gradient(135deg, #235185, #c45048);
}

.row-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(90px, 1fr));
  align-items: center;
  gap: 6px;
  width: 100%;
  min-width: 250px;
}

.row-actions form {
  margin: 0;
  width: 100%;
}

.btn-link-danger {
  border: 1px solid #d8e2ef;
  background: #f8fbff;
  color: #1f4772;
  font-weight: 700;
  cursor: pointer;
  padding: 5px 10px;
  border-radius: 8px;
  font-size: 12px;
}

.btn-link-danger:hover {
  color: #ffffff;
  background: #235185;
  border-color: #235185;
}

.table-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #d8e2ef;
  border-radius: 8px;
  background: #f8fbff;
  min-height: 30px;
  padding: 5px 10px;
  font-size: 12px;
  width: 100%;
  text-align: center;
}

.table-link.action-disabled {
  opacity: 0.5;
  pointer-events: none;
}

.table-link.action-view {
  color: #235185;
}

.table-link.action-edit {
  color: #266146;
}

.btn-link-danger.action-hide {
  color: #7a4d00;
}

.btn-link-danger.action-delete {
  color: #a8322b;
}

.table-link.action-view:hover,
.table-link.action-edit:hover {
  background: #235185;
  border-color: #1d446f;
  color: #ffffff;
}

.btn-link-danger.action-hide:hover,
.btn-link-danger.action-delete:hover {
  background: #c45048;
  border-color: #a23a33;
  color: #ffffff;
}

.pagination {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: flex-end;
  margin-top: 16px;
}

.page-link {
  display: inline-flex;
  padding: 8px 12px;
  border-radius: 8px;
  color: #ffffff;
  background: #235185;
  font-weight: 600;
}

.page-current {
  color: var(--text-soft);
  font-weight: 600;
}

.category-news-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.category-news-card {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 0;
  overflow: hidden;
}

.category-news-card .card-media {
  min-height: 100%;
  aspect-ratio: auto;
  height: 100%;
}

.category-news-card .card-body {
  display: flex;
  flex-direction: column;
  min-height: 128px;
  padding: 12px;
}

.category-news-card h3 {
  min-height: 44px;
  font-size: 18px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.category-news-card p {
  min-height: 40px;
  margin: 6px 0 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.category-news-card .meta {
  margin-top: auto;
}

.back-to-top {
  position: fixed;
  right: 18px;
  bottom: 18px;
  width: 46px;
  height: 46px;
  border-radius: 50%;
  border: none;
  background: #c45048;
  color: #ffffff;
  font-size: 22px;
  line-height: 1;
  box-shadow: 0 12px 24px rgba(21, 36, 54, 0.32);
  cursor: pointer;
  z-index: 99;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: opacity 0.2s ease, transform 0.2s ease, visibility 0.2s ease, background-color 0.2s ease;
}

.back-to-top.is-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.back-to-top:hover {
  background: #235185;
}

.ad-section {
  margin-top: 20px;
}

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

.ad-banner {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 120px;
  border-radius: 16px;
  border: 2px dashed rgba(35, 81, 133, 0.35);
  background: linear-gradient(135deg, rgba(35, 81, 133, 0.08), rgba(196, 80, 72, 0.08));
  color: #235185;
  font-weight: 800;
  letter-spacing: 0.6px;
}

.ad-banner span {
  text-align: center;
  padding: 0 14px;
}

.ad-banner-image {
  display: block;
  min-height: 0;
  height: auto;
  padding: 0;
  border-style: solid;
  overflow: visible;
}

.ad-banner-image img {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
}

.ad-widget .ad-square {
  width: 100%;
  aspect-ratio: 1 / 1;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 14px;
  border: 2px dashed rgba(35, 81, 133, 0.35);
  background: linear-gradient(160deg, rgba(35, 81, 133, 0.08), rgba(196, 80, 72, 0.08));
  color: #235185;
  font-weight: 800;
  text-align: center;
  padding: 14px;
}

.ad-square-image {
  display: block;
  aspect-ratio: auto;
  min-height: 0;
  height: auto;
  padding: 0;
  overflow: visible;
  border-style: solid;
}

.ad-square-image img {
  width: 100%;
  height: auto;
  object-fit: contain;
  display: block;
}

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

.home-sidebar {
  display: grid;
  gap: 14px;
  position: sticky;
  top: 112px;
}

.widget {
  background: #ffffff;
  border: 1px solid rgba(35, 81, 133, 0.14);
  border-radius: 16px;
  padding: 14px;
  box-shadow: 0 8px 24px rgba(35, 81, 133, 0.08);
}

.widget h3 {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 17px;
}

.embed-box {
  border-radius: 12px;
  overflow: hidden;
  background: #e9eff7;
}

.embed-box iframe {
  width: 100%;
  min-height: 220px;
  border: 0;
}

.widget .twitter-tweet,
.widget .tiktok-embed {
  margin: 0;
  width: 100%;
}

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

.category-pills a {
  display: block;
  text-align: center;
  padding: 10px 8px;
  border-radius: 10px;
  background: #eef3f9;
  color: var(--accent);
  font-weight: 600;
}

.category-pills a:hover {
  background: var(--accent);
  color: #ffffff;
}

.social-stack {
  display: grid;
  gap: 8px;
}

.social-stack a {
  display: block;
  background: linear-gradient(135deg, #235185, #c45048);
  color: #ffffff;
  border-radius: 10px;
  padding: 10px 12px;
  font-weight: 600;
}

.site-footer {
  background: linear-gradient(130deg, #235185, #1f4571);
  border-top: none;
}

.footer-bottom,
.site-footer p {
  color: #e1e9f2;
}

.footer-modern {
  padding-top: 34px;
  padding-bottom: 16px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.08);
}

.footer-top-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(0, 1.5fr) minmax(0, 0.85fr) minmax(0, 0.85fr);
  gap: 30px;
  align-items: stretch;
}

.footer-column {
  min-width: 0;
}

.footer-column h4 {
  margin: 0 0 14px;
  font-size: 21px;
  line-height: 1.1;
  letter-spacing: 0.2px;
  color: #ffffff;
}

.footer-list {
  display: grid;
  gap: 5px;
}

.footer-list a,
.footer-dual-list a {
  display: block;
  color: #eaf1f8;
  font-size: 13px;
  line-height: 1.3;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 100%;
  border-radius: 6px;
  padding: 2px 4px;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.footer-dual-list a {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
}

.footer-list a:hover,
.footer-dual-list a:hover {
  color: #ffffff;
  background: rgba(196, 80, 72, 0.95);
  text-decoration: none;
}

.footer-dual-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 18px;
}

.footer-column-brand .footer-logo {
  display: inline-flex;
  margin-top: auto;
}

.footer-column-brand {
  display: flex;
  flex-direction: column;
  min-height: 100%;
}

.footer-modern .footer-logo {
  width: auto;
  height: auto;
  border-radius: 0;
  background: transparent;
  border: none;
  margin-bottom: 0;
}

.footer-column-brand .footer-logo img {
  max-width: 170px;
  width: 100%;
  height: auto;
  object-fit: contain;
}

.footer-bottom-modern {
  margin-top: 20px;
  padding-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.22);
}

.footer-bottom-centered {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  text-align: center;
}

.footer-bottom-actions {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap;
}

.footer-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 36px;
  padding: 0 16px;
  border-radius: 999px;
  background: #ffffff;
  color: #235185;
  border: 1px solid rgba(255, 255, 255, 0.85);
  font-weight: 700;
  font-size: 13px;
  transition: all 0.2s ease;
}

.footer-cta:hover {
  background: #c45048;
  color: #ffffff;
  border-color: #c45048;
}

.content-page {
  padding: 24px 0 40px;
}

.content-card {
  background: #ffffff;
  border: 1px solid #d8e4f2;
  border-radius: 16px;
  box-shadow: 0 12px 28px rgba(24, 57, 97, 0.08);
  padding: 20px;
}

.content-card h1 {
  margin: 0 0 10px;
  color: #1a3f67;
}

.content-card p,
.content-card li {
  color: #35516d;
  line-height: 1.7;
}

.legal-doc h2 {
  margin: 18px 0 8px;
  color: #1e446f;
  font-size: 21px;
}

.legal-doc h3 {
  margin: 12px 0 6px;
  color: #29527d;
  font-size: 18px;
}

.legal-alert {
  background: #fff2f0;
  border: 1px solid #f0c7c2;
  border-radius: 10px;
  padding: 10px 12px;
}

.institutional-map {
  margin: 20px 0 0;
}

.institutional-map img {
  width: 100%;
  max-width: 760px;
  display: block;
  margin: 0 auto;
  height: auto;
}

.content-card ul {
  margin: 0;
  padding-left: 20px;
}

.public-form {
  display: grid;
  gap: 14px;
  margin-top: 14px;
}

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

.public-form label {
  display: grid;
  gap: 6px;
  color: #284764;
  font-weight: 600;
}

.public-form input,
.public-form textarea,
.public-form select {
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid #c8d8ec;
  background: #ffffff;
  color: #1c2f46;
}

.public-form input:focus,
.public-form textarea:focus,
.public-form select:focus {
  outline: none;
  border-color: #235185;
  box-shadow: 0 0 0 3px rgba(35, 81, 133, 0.16);
}

.public-form .field-full {
  grid-column: 1 / -1;
}

/* Admin theme refresh */
.admin-page {
  background:
    radial-gradient(circle at 0% 0%, rgba(35, 81, 133, 0.12), transparent 28%),
    radial-gradient(circle at 100% 0%, rgba(196, 80, 72, 0.1), transparent 32%),
    #eef3f9;
  color: #1c2f46;
}

.admin-main {
  padding: 26px 0 44px;
}

.admin-shell .editor-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.45fr) minmax(280px, 0.9fr);
  gap: 18px;
  margin-top: 14px;
}

.admin-shell .editor-column {
  min-width: 0;
}

.admin-shell .preview-column h3 {
  margin: 0 0 10px;
  color: #1f456e;
  font-size: 15px;
  letter-spacing: 0.2px;
}

.admin-shell .preview-card {
  background: #f8fbff;
  border: 1px solid #d6e3f1;
  border-radius: 14px;
  padding: 14px;
  box-shadow: 0 10px 24px rgba(25, 60, 98, 0.08);
}

.admin-shell .preview-cover-wrap {
  border-radius: 12px;
  overflow: hidden;
  background: #dce7f4;
  min-height: 160px;
  margin-bottom: 12px;
  position: relative;
}

.admin-shell .preview-cover-wrap img {
  width: 100%;
  height: 180px;
  object-fit: cover;
  display: block;
}

.admin-shell .preview-cover-wrap.is-empty img {
  display: none;
}

.admin-shell .preview-cover-placeholder {
  position: absolute;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  color: #5f7388;
  font-size: 14px;
}

.admin-shell .preview-cover-wrap.is-empty .preview-cover-placeholder {
  display: flex;
}

.admin-shell .preview-card h4 {
  margin: 0 0 8px;
  color: #183961;
  line-height: 1.3;
}

.admin-shell .preview-card > p {
  margin: 0 0 10px;
  color: #4f657d;
  line-height: 1.5;
}

.admin-shell .preview-content {
  border-top: 1px solid #d6e2f0;
  padding-top: 10px;
  color: #2b425b;
  line-height: 1.65;
  max-height: 320px;
  overflow: auto;
}

.admin-shell .quill-editor .ql-toolbar.ql-snow {
  background: #f6f9fd;
  border-bottom: 1px solid #d5e1ef;
  padding: 4px 6px;
}

.admin-shell .quill-editor .ql-toolbar.ql-snow .ql-formats {
  margin-right: 8px;
}

.admin-shell .quill-editor .ql-toolbar.ql-snow button,
.admin-shell .quill-editor .ql-toolbar.ql-snow .ql-picker-label {
  width: 24px;
  height: 24px;
}

.admin-shell .quill-editor .ql-toolbar.ql-snow .ql-picker.ql-header {
  width: 86px;
}

.admin-shell .quill-editor .ql-container.ql-snow {
  min-height: 360px;
}

.admin-shell .quill-editor .ql-editor {
  min-height: 360px;
  font-size: 17px;
  line-height: 1.75;
}

.admin-shell .container {
  max-width: 1280px;
  background: #ffffff;
  border: 1px solid #d7e2f0;
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 16px 36px rgba(25, 60, 98, 0.1);
}

.admin-shell .admin-header h2 {
  margin: 0;
  color: #183961;
  letter-spacing: 0.2px;
}

.admin-shell .admin-header p {
  margin: 6px 0 0;
  color: #5f7388;
}

.admin-shell .btn {
  background: #235185;
  color: #ffffff;
  border: 1px solid #1f4772;
}

.admin-shell .btn:hover {
  background: #1f4772;
}

.admin-shell .btn.secondary {
  background: #f4f7fb;
  color: #235185;
  border: 1px solid #c9d8ea;
}

.admin-shell .btn.secondary:hover {
  background: #e9f0f8;
}

.admin-shell .admin-form label {
  color: #304861;
  font-weight: 600;
}

.admin-shell .admin-form input,
.admin-shell .admin-form select,
.admin-shell .admin-form textarea {
  background: #ffffff;
  border: 1px solid #c8d7ea;
  color: #1c2f46;
}

.admin-shell .admin-form input:focus,
.admin-shell .admin-form select:focus,
.admin-shell .admin-form textarea:focus {
  outline: none;
  border-color: #235185;
  box-shadow: 0 0 0 3px rgba(35, 81, 133, 0.16);
}

.admin-shell .table {
  gap: 10px;
}

.admin-shell .table-head,
.admin-shell .table-row {
  background: #ffffff;
  border: 1px solid #d8e2ef;
  color: #1c2f46;
}

.admin-shell .table-head {
  background: linear-gradient(120deg, #ecf3fb, #f7fafe);
  color: #224a79;
}

.admin-shell .table-row:hover {
  border-color: #b7cce6;
  background: #f9fcff;
}

.admin-shell .table-link {
  color: inherit;
}

.admin-shell .table-link:hover {
  color: #ffffff;
}

.admin-shell .thumb-mini {
  border-color: #c4d5ea;
}

.admin-shell .thumb-icon {
  background: linear-gradient(135deg, #235185, #c45048);
}

.admin-shell .stat-card {
  background: linear-gradient(145deg, #235185, #1a3d64);
  border-color: rgba(255, 255, 255, 0.16);
}

.admin-shell .stat-card h3 {
  color: #d9e7f7;
}

.admin-shell .stat-card strong {
  color: #ffffff;
}

.admin-shell .quick-card {
  background: linear-gradient(135deg, #c45048, #a73f38);
  border-color: rgba(255, 255, 255, 0.12);
}

.admin-shell .settings-form {
  max-width: 920px;
  border-color: #d6e2f0;
  box-shadow: 0 12px 28px rgba(25, 60, 98, 0.08);
}

.admin-shell .btn-link-danger {
  color: inherit;
}

.admin-shell .btn-link-danger:hover {
  color: #ffffff;
}

.admin-most-read ul {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 8px;
}

.admin-most-read li {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.admin-most-read strong {
  color: #c45048;
}

.admin-shell .pagination {
  margin-top: 18px;
}

.admin-shell .page-link {
  background: #235185;
  color: #ffffff;
}

.admin-shell .page-link:hover {
  background: #1d446f;
}

.admin-shell .page-current {
  color: #4b6078;
}

.auth {
  max-width: 480px;
  background: #ffffff;
  border: 1px solid #d7e3f1;
  border-radius: 16px;
  padding: 20px;
  box-shadow: 0 12px 26px rgba(25, 60, 98, 0.08);
}

@media (max-width: 980px) {
  :root {
    --header-fixed-height: 248px;
    --header-bg-height: calc(100vw * 220 / 1920);
  }

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

  .menu-toggle {
    display: inline-flex;
  }

  .nav {
    display: none;
  }

  .nav.open {
    display: block;
  }

  .nav-item-dropdown {
    width: 100%;
  }

  .nav-dropdown-toggle {
    width: 100%;
    text-align: left;
  }

  .nav-dropdown-menu {
    position: static;
    margin-top: 8px;
    min-width: 100%;
  }

  .header-row {
    flex-direction: row;
    justify-content: flex-end;
    align-items: flex-end;
    height: var(--header-bg-height);
  }

  .nav-search {
    margin-left: 0;
    width: 100%;
  }

  .nav-search input {
    width: 100%;
  }

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

  .admin-stats {
    grid-template-columns: repeat(2, minmax(140px, 1fr));
  }

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

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

  .home-sidebar {
    position: static;
  }

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

  .hero-side-block {
    grid-template-columns: 1fr;
    grid-template-rows: auto;
  }

  .category-news-grid {
    grid-template-columns: 1fr;
  }

  .category-news-card {
    grid-template-columns: 1fr;
  }

  .category-news-card .card-media {
    min-height: 165px;
    height: auto;
  }

  .category-pills {
    grid-template-columns: 1fr;
  }

  .footer-top-grid {
    grid-template-columns: 1fr;
  }

  .footer-dual-list {
    grid-template-columns: 1fr;
    gap: 8px;
  }

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

  .tv-grid {
    grid-template-columns: 1fr;
  }

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

  .ad-top-grid {
    grid-template-columns: 1fr;
  }
}
