:root {
  color-scheme: light;
  --fs-bg: #f7f7f7;
  --fs-surface: #ffffff;
  --fs-border: #e6e6e6;
  --fs-primary: #b3231b;
  --fs-max-width: 1160px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  font-size: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--fs-bg);
  color: #1f1f1f;
  font-family: "Poppins", "Segoe UI", Arial, sans-serif;
}

img {
  display: block;
  height: auto;
  max-width: 100%;
}

#Main {
  background: var(--fs-bg);
}

.fs-home {
  max-width: var(--fs-max-width);
  margin: 0 auto;
  padding: 40px 20px 80px;
  display: flex;
  flex-direction: column;
  gap: 48px;
  color: #404040;
}

.fs-home h1,
.fs-home h2,
.fs-home h3 {
  font-family: "Poppins", "Segoe UI", Arial, sans-serif;
  font-weight: 700;
  color: #1f1f1f;
  margin: 0;
}

.fs-home h1 {
  font-size: 46px;
  line-height: 1.1;
}

.fs-home h2 {
  font-size: 32px;
  line-height: 1.25;
}

.fs-home h3 {
  font-size: 24px;
  line-height: 1.3;
}

.fs-section {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.fs-section p {
  margin: 0;
  line-height: 1.6;
  color: #404040;
  font-size: 16px;
}

.fs-section > p {
  color: #4a4a4a;
}

.fs-hero {
  gap: 16px;
  min-height: 220px;
  padding-top: 8px;
}

.fs-hero p {
  font-size: 18px;
  color: #4a4a4a;
  max-width: 820px;
}

.fs-last-update {
  font-size: 14px;
  color: #6b6b6b;
  margin: 8px 0 0;
}

.fs-cta,
.fs-card-cta,
.fs-detail-cta,
.fs-hero-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  background-color: var(--fs-primary);
  color: #ffffff !important;
  font-weight: 700;
  padding: 16px 36px;
  border-radius: 999px;
  transition: transform 0.2s ease, background-color 0.2s ease, box-shadow 0.2s ease;
  font-size: 18px;
  align-self: stretch;
  width: 100%;
  margin: 16px 0 0;
}

.fs-cta:hover,
.fs-card-cta:hover,
.fs-detail-cta:hover,
.fs-hero-cta:hover {
  transform: scale(1.03);
  background-color: #921c16;
  box-shadow: 0 12px 24px rgba(179, 35, 27, 0.35);
}

.fs-toc {
  border: 1px solid var(--fs-border);
  border-radius: 14px;
  background: var(--fs-surface);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.04);
  overflow: hidden;
}

.fs-toc summary {
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 16px 20px;
  font-weight: 600;
  font-size: 16px;
  color: #1f1f1f;
}

.fs-toc summary::-webkit-details-marker {
  display: none;
}

.fs-toc-label {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 13px;
  color: #6b6b6b;
}

.fs-toc-toggle {
  font-size: 14px;
  position: relative;
  padding-left: 20px;
  color: var(--fs-primary);
}

.fs-toc-toggle::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 12px;
  border-radius: 2px;
  border: 2px solid var(--fs-primary);
}

.fs-toc-toggle::after {
  content: attr(data-closed);
}

.fs-toc[open] .fs-toc-toggle::after {
  content: attr(data-open);
}

.fs-toc[open] .fs-toc-toggle::before {
  background: var(--fs-primary);
}

.fs-toc-body {
  border-top: 1px solid var(--fs-border);
  padding: 12px 20px 20px;
}

.fs-toc-list {
  margin: 0;
  padding-left: 16px;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  color: #404040;
  font-size: 15px;
}

.fs-toc-list a {
  color: var(--fs-primary);
  text-decoration: none;
  font-weight: 600;
}

.fs-toc-list a:hover {
  text-decoration: underline;
}

.fs-card {
  background: var(--fs-surface);
  border-radius: 16px;
  padding: 24px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.08);
  border: 1px solid var(--fs-border);
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-height: 100%;
}

.fs-card-full {
  background: linear-gradient(120deg, #0d1b2a, #1d3557);
  border: 0;
  color: #ffffff;
}

.fs-card-full h3,
.fs-card-full p,
.fs-card-full li {
  color: #ffffff;
}

.fs-card-description {
  font-size: 16px;
  color: #3a3a3a;
  margin: 0;
}

.fs-card-features {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 8px;
  color: #404040;
}

.fs-card-features li {
  font-size: 15px;
}

.fs-card-cta {
  margin-top: auto;
  margin-bottom: 0;
  width: 100%;
}

.fs-table-wrap {
  border-radius: 16px;
  overflow-x: auto;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.05);
  border: 1px solid var(--fs-border);
  background: var(--fs-surface);
}

.fs-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
}

.fs-table thead {
  background: #f5f5f5;
}

.fs-table th,
.fs-table td {
  padding: 16px 20px;
  text-align: left;
  font-size: 15px;
  border-bottom: 1px solid var(--fs-border);
  vertical-align: top;
  color: #404040;
}

.fs-table tbody tr:last-child td {
  border-bottom: none;
}

.fs-note {
  color: #6b6b6b;
  line-height: 1.6;
}

.fs-section ul,
.fs-section ol {
  margin: 0;
  padding-left: 20px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  color: #404040;
}

.fs-section li {
  line-height: 1.6;
}

/* Keep the original SmartWeb buttons readable with new palette */
.Button,
.Button .ButtonName,
.Button .ButtonName *,
.Button span {
  color: #ffffff !important;
}

.Button .ButtonName p {
  margin: 0;
}

/* Cookie widget styling (same approach as free-spiny) */
#privacy-buttons-container .privacy-button {
  background-color: var(--fs-primary);
  color: #ffffff !important;
  border: none;
  transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

#privacy-buttons-container .privacy-button:hover {
  background-color: #921c16;
  box-shadow: 0 8px 18px rgba(179, 35, 27, 0.35);
}

#privacy {
  display: none !important;
}

.site-footer {
  background: var(--fs-surface);
  border-top: 1px solid var(--fs-border);
  padding: 32px 20px;
}

.site-footer .FootData {
  max-width: var(--fs-max-width);
  margin: 0 auto;
}

.site-footer .Foot {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: center;
}

.site-footer a,
.site-footer p {
  margin: 0;
  color: #4a4a4a;
  text-align: center;
}

.site-footer a {
  color: var(--fs-primary);
  text-decoration: none;
  font-weight: 600;
}

.site-footer a:hover {
  text-decoration: underline;
}

.fs-lazy-section {
  content-visibility: auto;
  contain-intrinsic-size: 1200px;
}

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

.fs-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 700;
  font-size: 13px;
  letter-spacing: 0.02em;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid var(--fs-border);
  background: #fafafa;
  color: #333;
  width: fit-content;
}

.fs-stars {
  color: #f5a623;
  letter-spacing: 1px;
  font-size: 14px;
}

.fs-code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
  background: #f6f6f6;
  border: 1px solid var(--fs-border);
  border-radius: 12px;
  padding: 12px 14px;
  overflow-x: auto;
  color: #1f1f1f;
}

@media (max-width: 1200px) {
  .fs-home {
    padding: 48px 20px 72px;
  }
}

@media (max-width: 768px) {
  .fs-home {
    gap: 40px;
  }

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

  .fs-home h1 {
    font-size: 34px;
  }

  .fs-home h2 {
    font-size: 28px;
  }

  .fs-home h3 {
    font-size: 22px;
  }
}

@media (max-width: 640px) {
  .fs-table {
    min-width: 560px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
