* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Inter, Arial, sans-serif;
  color: #0f172a;
  background: #f8fafc;
}

a {
  color: #0f4c81;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.news-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
}

.news-site-header,
.news-site-footer {
  background: #0f172a;
  color: #fff;
}

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

.news-logo {
  height: 52px;
  width: auto;
}

.news-top-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  justify-content: center;
}

.news-top-nav a,
.news-lang-switch {
  color: #fff;
  font-weight: 600;
}

.news-site-footer {
  padding: 28px 0;
  margin-top: 48px;
}

.news-public-main {
  padding: 40px 0 56px;
}

.news-public-hero {
  margin-bottom: 32px;
}

.news-public-hero h1,
.news-card h1,
.news-toolbar h1 {
  margin: 0 0 12px;
  font-size: clamp(2rem, 4vw, 3rem);
  line-height: 1.1;
}

.news-card h2 {
  margin: 0 0 10px;
}

.news-card {
  background: #fff;
  border: 1px solid #dbe5ef;
  border-radius: 12px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  padding: 24px;
}

.news-card-narrow {
  max-width: 560px;
  margin: 40px auto;
}

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

.news-card-article {
  padding: 0;
  overflow: hidden;
}

.news-card-image-link {
  display: block;
}

.news-card-image {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  display: block;
}

.news-card-content {
  padding: 20px;
}

.news-meta {
  margin: 0 0 10px;
  color: #64748b;
  font-size: 14px;
}

.news-lead {
  font-size: 1.125rem;
  color: #334155;
}

.news-detail-cover {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  border-radius: 10px;
  margin: 16px 0 24px;
}

.news-detail-body {
  display: grid;
  gap: 16px;
  color: #334155;
  line-height: 1.7;
}

.news-detail-body p {
  margin: 0;
}

.news-detail-gallery {
  margin-top: 32px;
}

.news-gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.news-gallery-item,
.news-gallery-item-link {
  display: grid;
  gap: 10px;
}

.news-gallery-item img,
.news-gallery-item-link img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #dbe5ef;
}

.news-admin-body {
  background: #f1f5f9;
}

.news-admin-shell {
  width: min(1280px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 56px;
}

.news-toolbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
}

.news-toolbar p {
  margin: 0;
  color: #475569;
}

.news-toolbar-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.news-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 8px;
  border: 1px solid #0f4c81;
  background: #0f4c81;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
}

.news-button:hover {
  text-decoration: none;
  background: #0c3d67;
}

.news-button-secondary {
  background: #fff;
  color: #0f4c81;
}

.news-button-danger {
  background: #991b1b;
  border-color: #991b1b;
}

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

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

.news-form-stack,
.news-form-grid label {
  display: grid;
  gap: 8px;
}

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

input[type="text"],
input[type="password"],
input[type="datetime-local"],
input[type="file"],
textarea {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  background: #fff;
  font: inherit;
}

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

.news-checkbox {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.news-alert {
  padding: 12px 14px;
  border-radius: 8px;
  margin-bottom: 16px;
}

.news-alert-error {
  background: #fee2e2;
  color: #991b1b;
}

.news-existing-image {
  display: grid;
  gap: 12px;
}

.news-cover-preview,
.news-thumb {
  width: 100%;
  max-width: 220px;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid #dbe5ef;
}

.news-thumb {
  max-width: 120px;
}

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

.news-table {
  width: 100%;
  border-collapse: collapse;
}

.news-table th,
.news-table td {
  padding: 12px;
  border-bottom: 1px solid #e2e8f0;
  vertical-align: top;
  text-align: left;
}

.news-table-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

@media (max-width: 900px) {
  .news-form-grid {
    grid-template-columns: 1fr;
  }

  .news-toolbar,
  .news-header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .news-top-nav {
    justify-content: flex-start;
  }
}
