@import url("https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,500;9..144,700&family=Manrope:wght@400;500;600;700&display=swap");

:root {
  --bg-main: #f5efe6;
  --bg-soft: #fffaf2;
  --surface: #ffffff;
  --surface-muted: #fff6e8;
  --text-main: #2f241e;
  --text-muted: #6d5b50;
  --brand: #c7682e;
  --brand-strong: #a84f1c;
  --line: #eddccc;
  --success-soft: #ebf8ef;
  --danger-soft: #fde9e5;
  --shadow-soft: 0 14px 30px rgba(93, 52, 32, 0.12);
  --radius-lg: 22px;
  --radius-md: 14px;
}

html {
  position: relative;
  min-height: 100%;
  font-size: 15px;
}

@media (min-width: 992px) {
  html {
    font-size: 16px;
  }
}

body {
  margin: 0;
  color: var(--text-main);
  font-family: "Manrope", "Segoe UI", sans-serif;
  line-height: 1.65;
  background:
    radial-gradient(circle at 5% 5%, rgba(255, 201, 136, 0.28), transparent 40%),
    radial-gradient(circle at 92% 10%, rgba(230, 164, 94, 0.2), transparent 35%),
    linear-gradient(180deg, var(--bg-soft) 0%, var(--bg-main) 100%);
}

.app-shell {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(6px);
}

.app-navbar {
  border: 0;
  border-bottom: 1px solid rgba(237, 220, 204, 0.8);
  background: rgba(255, 250, 242, 0.92) !important;
  box-shadow: 0 8px 20px rgba(93, 52, 32, 0.08);
}

.app-navbar .navbar-brand {
  font-family: "Fraunces", Georgia, serif;
  font-size: 1.45rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--brand-strong);
}

.app-navbar .nav-link {
  color: var(--text-main) !important;
  border-radius: 999px;
  padding: 0.48rem 0.9rem !important;
  margin-right: 0.28rem;
  font-weight: 600;
  transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.app-navbar .nav-link:hover,
.app-navbar .nav-link:focus-visible {
  color: var(--brand-strong) !important;
  background: #fff2de;
  transform: translateY(-1px);
}

.language-selector {
  min-width: 8.7rem;
  border-radius: 999px;
  border: 1px solid #e7d4bf;
  background: #fffdf9;
  color: var(--text-main);
  font-weight: 600;
  padding: 0.35rem 2rem 0.35rem 0.75rem;
}

.app-main-container {
  flex: 1;
  margin-top: 1.25rem;
}

.page-content {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: clamp(1.2rem, 1rem + 1vw, 2.1rem);
}

h1,
h2,
h3,
h4 {
  font-family: "Fraunces", Georgia, serif;
  color: #3e2a20;
}

h1 {
  font-size: clamp(1.8rem, 1.45rem + 1vw, 2.5rem);
  margin-bottom: 1rem;
}

h2 {
  font-size: clamp(1.35rem, 1.2rem + 0.45vw, 1.8rem);
  margin-top: 1.6rem;
}

p,
li,
label,
th,
td {
  color: var(--text-main);
}

a {
  color: var(--brand-strong);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: #8f4318;
}

form {
  background: var(--surface-muted);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 1rem 1.05rem;
  margin-bottom: 1rem;
}

input.form-control,
textarea.form-control,
select.form-control {
  border-radius: 12px;
  border: 1px solid #e6d2be;
  background: #fff;
  color: var(--text-main);
}

textarea.form-control {
  min-height: 140px;
}

.form-control:focus,
.form-select:focus,
.form-check-input:focus,
.btn:focus,
.btn:focus-visible {
  border-color: #d59b75;
  box-shadow: 0 0 0 0.22rem rgba(199, 104, 46, 0.2);
}

.btn {
  border-radius: 11px;
  font-weight: 700;
  letter-spacing: 0.01em;
  padding: 0.5rem 1rem;
}

.btn-primary {
  color: #fff;
  border: 1px solid var(--brand);
  background: linear-gradient(135deg, #ce7238 0%, #b5551f 100%);
}

.btn-primary:hover {
  border-color: #9f4a19;
  background: linear-gradient(135deg, #b96533 0%, #a04617 100%);
}

.btn-danger {
  border: 1px solid #c94435;
  background: linear-gradient(135deg, #de5e4f 0%, #bb3e32 100%);
}

.validation-summary-errors,
span.field-validation-error {
  color: #ab2f26;
  font-weight: 600;
}

.alert.alert-info {
  border: 1px solid #cfe9d8;
  background: var(--success-soft);
  color: #285538;
}

.table {
  margin-top: 0.9rem;
  border-collapse: separate;
  border-spacing: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.table th {
  background: #fdf1df;
  border-bottom: 1px solid var(--line);
  font-weight: 700;
}

.table > :not(caption) > * > * {
  padding: 0.78rem 0.75rem;
  border-bottom-color: #f1e2d1;
}

.table tr:last-child td {
  border-bottom: 0;
}

.pagination {
  gap: 0.35rem;
  margin-top: 1rem;
}

.pagination .page-item {
  list-style: none;
  min-width: 2rem;
  text-align: center;
  border: 1px solid #e7d3bf;
  border-radius: 10px;
  padding: 0.28rem 0.58rem;
  background: #fff;
}

.pagination .page-item a {
  text-decoration: none;
}

.nav {
  gap: 0.5rem;
  margin-bottom: 0.85rem;
}

.nav .nav-link {
  border: 1px solid #ecd8c2;
  border-radius: 999px;
  background: #fff7ec;
  color: var(--text-main);
  font-weight: 600;
}

.nav .nav-link:hover {
  background: #ffeccf;
}

input[type="checkbox"][id^="t_"] {
  position: absolute;
  opacity: 0;
}

input[type="checkbox"][id^="t_"] + label {
  display: inline-block;
  margin: 0 0.38rem 0.48rem 0;
  padding: 0.27rem 0.68rem;
  border-radius: 999px;
  border: 1px solid #e2ccb7;
  background: #fff;
  cursor: pointer;
  font-size: 0.92rem;
}

input[type="checkbox"][id^="t_"]:checked + label {
  border-color: #db9e76;
  background: #ffedd6;
  color: #7d3513;
}

main ul,
main ol {
  padding-left: 1.25rem;
}

.app-footer {
  position: static;
  margin-top: 1.2rem;
  width: 100%;
  border-top: 1px solid #e7d6c5 !important;
  background: rgba(255, 250, 242, 0.85);
  color: var(--text-muted) !important;
}

.app-footer .container {
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

.text-danger {
  color: #bd3f35 !important;
}

@media (max-width: 768px) {
  .page-content {
    border-radius: 18px;
    padding: 1rem 0.85rem;
  }

  form .row > [class*="col-"] {
    margin-bottom: 0.5rem;
  }

  .app-navbar .nav-link {
    margin-bottom: 0.2rem;
  }
}
