/* Общие настройки */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    scroll-behavior: smooth;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.6;
    background-image: url('/static/images/mainz_backgraund.webp');
    background-size: cover;
    background-position: center;
    color: #333;
    margin: 0;
}

/* Заголовок */
header {
    background: rgba(29, 53, 87, 0.9);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    position: relative;
    z-index: 10;
}

header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 15px 20px;
    flex-wrap: wrap;
}

/* Логотип */
.logo img {
    height: 120px;
    max-height: 100%;
    border-radius: 25px;
    width: auto;
    display: block;
    min-width: 180px;
    filter: drop-shadow(0 0 6px rgba(255, 255, 255, 0.8));
}

/* Навигация */
nav ul {
    list-style: none;
    display: flex;
    gap: 30px;
    margin: 0;
    padding: 0;
}

nav ul li a {
    color: #ffffff;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 12px;
    border-radius: 4px;
    transition: background-color 0.5s ease;
}

nav ul li a:hover {
    background-color: #457b9d;
    color: #f4a261;
}

@media (max-width: 768px) {
    header .container {
        flex-direction: column;
        align-items: flex-start;
    }

    .logo img {
        height: 100px;
        min-width: unset;
    }

    nav ul {
        flex-direction: column;
        width: 100%;
        gap: 10px;
        margin-top: 10px;
    }

    nav ul li {
        width: 100%;
    }

    nav ul li a {
        display: block;
        width: 100%;
        padding: 10px;
        background: rgba(255, 255, 255, 0.05);
    }
}


/* Социальные ссылки */
.social-links {
    text-align: center;
    margin-top: 20px;
}

.social-links a {
    display: inline-block;
    margin: 10px;
    padding: 10px;
    border-radius: 5px;
    background-color: #f0f4f8;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.social-links a img {
    width: 40px;
    height: 40px;
}

.social-links a:hover {
    background-color: #457b9d;
    transform: scale(1.1);
}

/* Основные секции */
section {
    padding: 60px;
    margin: 30px auto;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 15px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    max-width: 1000px;
}

/* Карточки услуг */
.service {
    display: flex;
    align-items: center;
    margin-bottom: 40px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.service:hover {
    transform: translateY(-10px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.25);
}

.service img {
    max-width: 220px;
    height: auto;
    margin-right: 30px;
    border-radius: 12px;
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.service-content h3 {
    font-size: 1.8rem;
    color: #1d3557;
    margin-bottom: 10px;
}

.service-content p {
    font-size: 1.1rem;
    margin-bottom: 10px;
    color: #333;
}

.price {
    font-weight: bold;
    color: #e67e22;
    font-size: 1.2rem;
}

/* Анимации цен */
.original-price {
    position: relative;
    display: inline-block;
    color: red;
    font-size: 1.4rem;
    margin-right: 5px;
}

/*
   Псевдоэлемент ::after рисует диагональную линию
   на 50% пути (вместо 100%+)
   Высота линии 4px, анимация 3s.
*/
.original-price::after {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 0;
    height: 4px;
    background: red;
    transform: rotate(45deg) translateY(-50%);
    transform-origin: left center;
    animation: diagonalStrike 3s infinite ease-in-out;
}

/* Укороченное до 100% (вместо 200%) */
@keyframes diagonalStrike {
    0%, 100% {
        width: 0;
    }
    50% {
        width: 100%;
    }
}

.special-price {
    color: green;
    font-weight: bold;
    margin-right: 5px;
    font-size: 1.4rem;
    animation: fadeBounce 3s infinite ease-in-out;
}

@keyframes fadeBounce {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0;
        transform: scale(0.95);
    }
}

/* Лёгкое выделение */
.limited-offer {
    background-color: #d4edda;
    font-style: italic;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Таймер */
.countdown-offer {
    font-size: 1.2rem;
    margin-bottom: 30px;
    text-align: center;
}

#timer {
    font-family: "Courier New", Courier, monospace;
    font-size: 1.2em;
}

.time-part {
    background: #1d3557;
    color: #fff;
    padding: 5px 8px;
    margin: 0 2px;
    border-radius: 5px;
    display: inline-block;
    min-width: 2ch;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.3);
}

/* Кнопки */
.service-content button {
    background-color: #457b9d;
    color: #ffffff;
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    font-size: 1.1rem;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.service-content button:hover {
    background-color: #1d3557;
}

.btn-teamviewer {
    background-color: #25D366;
    color: #ffffff;
    border: none;
    padding: 12px 24px;
    font-size: 1rem;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.btn-teamviewer:hover {
    background-color: #128C7E;
    transform: scale(1.05);
}

/* Форма */
form {
    display: flex;
    flex-direction: column;
}

form label {
    margin-bottom: 5px;
    font-weight: bold;
    color: #1d3557;
}

form input,
form textarea {
    margin-bottom: 20px;
    padding: 15px;
    font-size: 1rem;
    border: 2px solid #ddd;
    border-radius: 5px;
    transition: border-color 0.3s ease;
}

form input:focus,
form textarea:focus {
    border-color: #457b9d;
    outline: none;
}

form button {
    background-color: #e67e22;
    color: #ffffff;
    padding: 15px;
    font-size: 1rem;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

form button:hover {
    background-color: #d35400;
}

/* Футер */
footer {
    text-align: center;
    padding: 20px 0;
    background: #1d3557;
    color: #ffffff;
    box-shadow: 0 -4px 8px rgba(0, 0, 0, 0.2);
}

footer p {
    margin: 5px 0;
    font-size: 0.9rem;
}

footer p a {
    color: #f4a261;
    text-decoration: none;
}

footer p a:hover {
    text-decoration: underline;
}

/* Анимация успеха (зелёная галочка) */
.success-animation {
    display: none;
    width: 100%;
    height: 100%;
    position: fixed;
    top: 0;
    left: 0;
    background: rgba(255, 255, 255, 0.9);
    justify-content: center;
    align-items: center;
    z-index: 1000;
    flex-direction: column;
    text-align: center;
    padding: 20px;
}

.success-animation.active {
    display: flex;
}

.checkmark {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    display: block;
    stroke-width: 2;
    stroke: #4CAF50;
    stroke-miterlimit: 10;
    box-shadow: inset 0px 0px 0px #4CAF50;
    animation: fill .6s ease-in-out .4s forwards, scale .3s ease-in-out .9s both;
    margin-bottom: 20px;
}

.checkmark__circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke: #4CAF50;
    fill: none;
    animation: strokeCircle 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.checkmark__check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    animation: strokeCheck 0.3s cubic-bezier(0.65, 0, 0.45, 1) 0.8s forwards;
    stroke-linecap: round;
}

/* Анимации для круга и галочки */
@keyframes strokeCircle {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes strokeCheck {
    100% {
        stroke-dashoffset: 0;
    }
}

@keyframes fill {
    100% {
        box-shadow: inset 0px 0px 0px 70px #4CAF50;
    }
}

@keyframes scale {
    0%, 100% {
        transform: none;
    }
    50% {
        transform: scale3d(1.03, 1.03, 1);
    }
}

.success-message {
    font-size: 1.2rem;
    color: #333;
    font-weight: bold;
}

/* Адаптивность */
@media (max-width: 768px) {
    section {
        padding: 20px;
        margin: 10px auto;
        max-width: 100%;
    }

    header .container {
        padding: 10px;
        flex-direction: column;
        align-items: center;
    }

    .logo img {
        height: 50px;
    }

    nav ul {
        position: absolute;
        top: 70px;
        left: -100%;
        width: 100%;
        text-align: center;
    }

    nav ul.active {
        left: 0;
    }

    .menu-toggle {
        display: flex;
    }

    .service {
        flex-direction: column;
        text-align: center;
    }

    .service img {
        max-width: 100%;
        margin: 0 0 20px 0;
    }

    form input,
    form textarea {
        width: 100%;
    }

    .btn-teamviewer, button[type="submit"] {
        width: 100%;
    }
}

@media (max-width: 480px) {
    h1, h2, h3 {
        font-size: 1.2rem;
    }

    .service-content h3 {
        font-size: 1.2rem;
    }

    .price {
        font-size: 1rem;
    }

    .btn-teamviewer, form button {
        font-size: 0.9rem;
        padding: 12px;
    }
}

.cookie-consent {
  position: fixed;
  bottom: 0;
  width: 100%;
  background: #1d3557;
  color: #fff;
  padding: 15px;
  box-shadow: 0 -2px 10px rgba(0,0,0,0.2);
  display: none;
  z-index: 9999;
}

.cookie-box {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
}

.cookie-box p {
  margin: 0;
  font-size: 14px;
}

.cookie-box a {
  color: #f4a261;
  text-decoration: underline;
}

.cookie-buttons button {
  margin-left: 10px;
  padding: 8px 16px;
  background-color: #f4a261;
  color: #000;
  border: none;
  border-radius: 4px;
  cursor: pointer;
}

.cookie-buttons button:hover {
  background-color: #e67e22;
}

.cookie-blocker {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(29, 53, 87, 0.95);
  color: #fff;
  z-index: 9998; /* чуть ниже баннера */
  display: flex;
  justify-content: center;
  align-items: center;
  text-align: center;
  padding: 20px;
}

.cookie-blocker.hidden {
  display: none;
}

.cookie-overlay-box {
  background: #1d3557;
  border: 1px solid #f4a261;
  padding: 30px;
  border-radius: 12px;
  max-width: 600px;
  box-shadow: 0 0 20px rgba(0,0,0,0.4);
}

.cookie-overlay-box h2 {
  margin-top: 0;
}

.cookie-overlay-box button {
  background: #f4a261;
  border: none;
  color: #000;
  padding: 10px 20px;
  margin-top: 20px;
  border-radius: 6px;
  cursor: pointer;
}

.cookie-overlay-box button:hover {
  background: #e67e22;
}
