:root {
  --primary-color: #0d6efd;
  --secondary-color: #6c757d;
  --accent-color: #ffc107;
  --light-color: #f8f9fa;
  --dark-color: #212529;
  --success-color: #198754;
  --font-main: 'Roboto', sans-serif;
  --font-heading: 'Montserrat', sans-serif;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: var(--font-main);
  line-height: 1.6;
  color: var(--dark-color);
  background-color: #f5f7fa;
}

.container {
  width: 90%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 15px;
}

/* Шапка сайта */
.header {
  background: linear-gradient(135deg, #0a4da3 0%, #0d6efd 100%);
  color: white;
  padding: 1rem 0;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
}

.logo img {
  height: 50px;
  margin-right: 10px;
}

.logo-text {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 700;
  color: white;
  text-decoration: none;
}

.nav {
  display: flex;
}

.nav-link {
  color: white;
  text-decoration: none;
  padding: 0.5rem 1rem;
  margin: 0 0.2rem;
  border-radius: 4px;
  transition: background-color 0.3s;
  font-weight: 500;
}

.nav-link:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

.nav-link.active {
  background-color: rgba(255, 255, 255, 0.3);
}

/* Основной контент */
.main {
  padding: 3rem 0;
}

.page-title {
  font-family: var(--font-heading);
  font-size: 2.5rem;
  margin-bottom: 2rem;
  color: var(--primary-color);
  text-align: center;
}

.subtitle {
  font-size: 1.2rem;
  text-align: center;
  margin-bottom: 3rem;
  color: var(--secondary-color);
}

.posts-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  margin-bottom: 3rem;
}

.post-card {
  background-color: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s, box-shadow 0.3s;
}

.post-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.post-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.post-content {
  padding: 1.5rem;
}

.post-date {
  font-size: 0.85rem;
  color: var(--secondary-color);
  margin-bottom: 0.5rem;
}

.post-title {
  font-size: 1.4rem;
  margin-bottom: 0.75rem;
  font-family: var(--font-heading);
  font-weight: 600;
}

.post-excerpt {
  color: #666;
  margin-bottom: 1.5rem;
}

.btn {
  display: inline-block;
  padding: 0.5rem 1rem;
  border-radius: 4px;
  text-decoration: none;
  font-weight: 500;
  transition: background-color 0.3s, color 0.3s;
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
}

.btn-primary:hover {
  background-color: #0a58ca;
}

.btn-outline {
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
}

.btn-outline:hover {
  background-color: var(--primary-color);
  color: white;
}

/* Раздел Ошибки новичков */
.mistakes-section {
  background-color: white;
  padding: 3rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  margin-bottom: 3rem;
}

.section-title {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
  color: var(--primary-color);
  position: relative;
}

.section-title:after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 60px;
  height: 3px;
  background-color: var(--accent-color);
}

.mistakes-list {
  list-style: none;
  margin-top: 1.5rem;
}

.mistake-item {
  margin-bottom: 1rem;
  padding: 1rem;
  border-left: 3px solid var(--accent-color);
  background-color: #f8f9fa;
  transition: transform 0.3s;
}

.mistake-item:hover {
  transform: translateX(5px);
}

.mistake-title {
  font-weight: 600;
  color: var(--primary-color);
  margin-bottom: 0.5rem;
}

/* Таймер */
.countdown-section {
  background: linear-gradient(135deg, #0a4da3 0%, #0d6efd 100%);
  color: white;
  padding: 3rem;
  border-radius: 8px;
  margin-bottom: 3rem;
  text-align: center;
}

.countdown-title {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin-bottom: 1.5rem;
}

.countdown-container {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin: 2rem 0;
}

.countdown-box {
  background-color: rgba(255, 255, 255, 0.2);
  padding: 1.5rem;
  border-radius: 8px;
  min-width: 100px;
}

.countdown-value {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.countdown-label {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.countdown-info {
  margin-top: 1.5rem;
  font-size: 1.1rem;
}

/* Подвал сайта */
.footer {
  background-color: var(--dark-color);
  color: white;
  padding: 3rem 0;
}

.footer-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 2rem;
}

.footer-section {
  flex: 1;
  min-width: 200px;
}

.footer-title {
  font-family: var(--font-heading);
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  position: relative;
}

.footer-title:after {
  content: '';
  position: absolute;
  bottom: -10px;
  left: 0;
  width: 40px;
  height: 3px;
  background-color: var(--accent-color);
}

.footer-links {
  list-style: none;
}

.footer-link {
  margin-bottom: 0.75rem;
}

.footer-link a {
  color: #adb5bd;
  text-decoration: none;
  transition: color 0.3s;
}

.footer-link a:hover {
  color: white;
}

.footer-contact {
  margin-bottom: 0.75rem;
  display: flex;
  align-items: flex-start;
}

.footer-contact i {
  margin-right: 10px;
  color: var(--accent-color);
}

.social-links {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.social-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.1);
  color: white;
  transition: background-color 0.3s;
}

.social-icon:hover {
  background-color: var(--primary-color);
}

.copyright {
  text-align: center;
  padding-top: 2rem;
  margin-top: 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  color: #adb5bd;
}

/* Стили для страницы About */
.team-section {
  margin: 3rem 0;
}

.team-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 2rem;
}

.team-card {
  background-color: white;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s;
}

.team-card:hover {
  transform: translateY(-5px);
}

.team-img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
}

.team-content {
  padding: 1.5rem;
}

.team-name {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  margin-bottom: 0.5rem;
  color: var(--primary-color);
}

.team-position {
  font-weight: 500;
  color: var(--secondary-color);
  margin-bottom: 1rem;
}

.team-bio {
  color: #666;
  font-size: 0.95rem;
}

/* Стили для страницы контактов */
.contact-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 3rem;
}

.contact-info {
  background-color: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.contact-item {
  margin-bottom: 1.5rem;
  display: flex;
  align-items: flex-start;
}

.contact-icon {
  width: 40px;
  height: 40px;
  background-color: var(--primary-color);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  flex-shrink: 0;
}

.contact-text h4 {
  font-size: 1.1rem;
  color: var(--primary-color);
  margin-bottom: 0.25rem;
}

.contact-text p {
  color: #666;
}

.contact-form {
  background-color: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

.form-control {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-family: inherit;
  font-size: 1rem;
  transition: border-color 0.3s;
}

.form-control:focus {
  outline: none;
  border-color: var(--primary-color);
}

textarea.form-control {
  resize: vertical;
  min-height: 150px;
}

.btn-submit {
  background-color: var(--primary-color);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 500;
  transition: background-color 0.3s;
  width: 100%;
}

.btn-submit:hover {
  background-color: #0a58ca;
}

/* Страница поста */
.post-header {
  margin-bottom: 3rem;
}

.post-meta {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  color: var(--secondary-color);
  font-size: 0.9rem;
}

.post-featured-img {
  width: 100%;
  max-height: 500px;
  object-fit: cover;
  border-radius: 8px;
  margin-bottom: 2rem;
}

.post-body {
  background-color: white;
  padding: 2rem;
  border-radius: 8px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.post-body h2 {
  font-family: var(--font-heading);
  font-size: 1.8rem;
  margin: 2rem 0 1rem;
  color: var(--primary-color);
}

.post-body p {
  margin-bottom: 1.5rem;
  line-height: 1.8;
}

.post-body ul, .post-body ol {
  margin-bottom: 1.5rem;
  padding-left: 2rem;
}

.post-body li {
  margin-bottom: 0.5rem;
}

.post-body blockquote {
  border-left: 4px solid var(--accent-color);
  padding: 1rem 2rem;
  background-color: #f8f9fa;
  margin: 1.5rem 0;
}

.tags-section {
  margin-top: 2rem;
}

.tag {
  display: inline-block;
  background-color: #e9ecef;
  color: var(--secondary-color);
  padding: 0.3rem 0.8rem;
  border-radius: 20px;
  margin-right: 0.5rem;
  margin-bottom: 0.5rem;
  font-size: 0.85rem;
}

/* Стили для cookie плашки */
.cookie-banner {
  position: fixed;
  bottom: 20px;
  left: 20px;
  right: 20px;
  background-color: white;
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  z-index: 1000;
}

.cookie-message {
  flex: 1;
  min-width: 280px;
}

.cookie-message h3 {
  font-family: var(--font-heading);
  font-size: 1.2rem;
  margin-bottom: 0.5rem;
}

.cookie-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cookie-btn {
  padding: 0.5rem 1rem;
  border-radius: 4px;
  cursor: pointer;
  font-weight: 500;
  border: none;
}

.cookie-btn-accept {
  background-color: var(--success-color);
  color: white;
}

.cookie-btn-settings {
  background-color: var(--light-color);
  color: var(--dark-color);
  border: 1px solid #ddd;
}

.cookie-btn-decline {
  background-color: var(--light-color);
  color: var(--secondary-color);
  border: 1px solid #ddd;
}

/* Адаптивность */
@media (max-width: 992px) {
  .header-content {
    flex-direction: column;
  }
  
  .logo {
    margin-bottom: 1rem;
  }
  
  .nav {
    width: 100%;
    justify-content: center;
    flex-wrap: wrap;
  }
  
  .countdown-container {
    flex-wrap: wrap;
  }
  
  .countdown-box {
    min-width: 80px;
  }
}

@media (max-width: 768px) {
  .page-title {
    font-size: 2rem;
  }
  
  .mistakes-section, .countdown-section, .contact-form, .contact-info {
    padding: 1.5rem;
  }
  
  .footer-container {
    flex-direction: column;
    gap: 2rem;
  }
  
  .cookie-banner {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .cookie-buttons {
    width: 100%;
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .nav-link {
    padding: 0.5rem;
    margin: 0.1rem;
    font-size: 0.9rem;
  }
  
  .countdown-box {
    min-width: 60px;
    padding: 1rem;
  }
  
  .countdown-value {
    font-size: 1.8rem;
  }
}
