/* ================================
   BASE — фундамент стилей LiberCom
   ================================ */

/* ---------- CSS VARIABLES ---------- */
:root {
  --color-bg: #ffffff;
  --color-bg-soft: #f8f8f8;

  --color-text-main: #222222;
  --color-text-muted: #666666;

  --color-primary: #2c5eff;
  --color-primary-hover: #1f4ed8;

  --color-border: #e2e2e2;
  --color-gold: #c9a24d;

  --radius-sm: 6px;
  --radius-md: 10px;
}

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

html {
  font-size: 16px;
}

body {
  margin: 0;
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--color-text-main);
  background-color: var(--color-bg);
  line-height: 1.6;
}

/* ---------- LAYOUT ---------- */
.container {
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 16px;
}

.hidden {
  display: none !important;
}

.text-center {
  text-align: center;
}

/* ---------- LINKS ---------- */
a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--color-primary-hover);
  text-decoration: underline;
}

/* ---------- HEADERS ---------- */
h1, h2, h3 {
  color: #111;
  margin-top: 1.5em;
  margin-bottom: 0.5em;
  line-height: 1.3;
}

h1 {
  font-size: 2rem;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.1rem;
}

/* ---------- TEXT ---------- */
p {
  margin: 0.5em 0;
}

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

/* ---------- LISTS ---------- */
ul {
  padding-left: 20px;
  margin: 0.5em 0;
}

li {
  margin-bottom: 6px;
}

/* ---------- HEADER / FOOTER ---------- */
header,
footer {
  background-color: var(--color-bg-soft);
}

footer {
  font-size: 0.9rem;
  color: #555;
  text-align: center;
}

/* ---------- FORMS BASIC ---------- */
input,
select,
textarea {
  font-family: inherit;
  font-size: 14px;
}

button {
  font-family: inherit;
  font-size: 14px;
  cursor: pointer;
  background: none;
  border: none;
}

/* ---------- IMAGES ---------- */
img {
  max-width: 100%;
  display: block;
}

/* ---------- ANIMATIONS ---------- */
.fade-in {
  animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
/* ---------- DYNAMIC SITE BACKGROUND / THEMES ---------- */
body {
  background-color: var(--color-bg);
  background-image: var(--site-background-image, none);
  background-size: var(--site-background-size, cover);
  background-position: var(--site-background-position, center top);
  background-repeat: var(--site-background-repeat, no-repeat);
  background-attachment: fixed;
}

:root[data-theme="dark"] h1,
:root[data-theme="dark"] h2,
:root[data-theme="dark"] h3 { color: var(--color-text-main); }

:root[data-theme="dark"] input,
:root[data-theme="dark"] select,
:root[data-theme="dark"] textarea {
  background: #1f2228;
  color: var(--color-text-main);
}
