:root {
  --color-primary: #75c3ff;
  --color-secondary: #ffa000;
  --color-background: #ffffff;
  --color-text: #2b2b2b;
}

*, *::before, *::after {
    box-sizing: border-box;
    border-width: 0;
    border-style: solid;
    border-color: var(--color-secondary);
}

html {
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

body.site-page {
    margin: 0;
    background-color: var(--color-background);
    color: var(--color-text);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    color: inherit;
    text-decoration: inherit;
}

/* --- Контейнери (Container) --- */
.site-header__inner,
.site-article,
.site-footer__inner {
    width: 100%;
    max-width: 1280px; /* max-w-7xl */
    margin-left: auto;
    margin-right: auto;
    padding-left: 1.5rem; /* px-6 */
    padding-right: 1.5rem;
}

.site-shell {
    display: flex;
    flex-direction: column;
    flex: 1 1 0%;
}

/* --- Шапка (Header) --- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    /* Напівпрозорий фон з розмиттям (backdrop-blur-md) */
    background-color: color-mix(in srgb, var(--color-background) 85%, transparent);
    backdrop-filter: blur(12px);
    border-bottom-width: 1px;
}

.site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 4rem; /* h-16 */
    gap: 1.5rem;
}

.site-header__logo-link {
    display: flex;
    align-items: center;
}

.site-header__logo {
    height: 2rem; /* h-8 */
    width: auto;
}

/* --- Навігація (Nav) --- */
.site-header__nav {
    display: flex;
    align-items: center;
}

.site-menu {
    display: flex;
    gap: 0.5rem; /* space-x-2 */
    margin: 0;
    padding: 0;
    list-style-type: none;
}

.site-menu__link {
    display: block;
    padding: 0.5rem 0.75rem; /* px-3 py-2 */
    font-size: 0.875rem; /* text-sm */
    font-weight: 500; /* font-medium */
    border-radius: 0.375rem; /* rounded-md */
    /* Використовуємо color-mix для створення світлішого відтінку тексту (slate-600) */
    color: color-mix(in srgb, var(--color-text) 75%, transparent);
    transition-property: color, background-color;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
}

.site-menu__link:hover {
    color: var(--color-text);
    background-color: color-mix(in srgb, var(--color-secondary) 50%, transparent);
}

/* --- Кнопки (Buttons) --- */
.site-header__cta {
    display: flex;
    align-items: center;
    gap: 0.75rem; /* space-x-3 */
}

.site-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 1rem; /* px-4 py-2 */
    font-size: 0.875rem; /* text-sm */
    font-weight: 600; /* font-semibold */
    border-radius: 0.5rem; /* rounded-lg */
    transition-property: background-color, opacity, box-shadow;
    transition-timing-function: cubic-bezier(0.4, 0, 0.2, 1);
    transition-duration: 150ms;
    /* Стиль Primary */
    background-color: var(--color-primary);
    color: var(--color-background);
    /* Тінь: shadow-sm */
    box-shadow: 0 1px 2px 0 color-mix(in srgb, var(--color-text) 10%, transparent);
}

.site-button:hover {
    opacity: 0.9;
    /* Тінь: shadow-md на ховері */
    box-shadow: 0 4px 6px -1px color-mix(in srgb, var(--color-text) 10%, transparent), 
                0 2px 4px -2px color-mix(in srgb, var(--color-text) 10%, transparent);
}

.site-button--secondary {
    background-color: transparent;
    color: var(--color-text);
    border-width: 1px;
    box-shadow: 0 1px 2px 0 color-mix(in srgb, var(--color-text) 5%, transparent);
}

.site-button--secondary:hover {
    background-color: color-mix(in srgb, var(--color-secondary) 50%, transparent);
    opacity: 1;
}

/* --- Основний контент (Main & Hero) --- */
.site-main {
    flex: 1 1 0%;
    padding-top: 3rem; /* pt-12 */
    padding-bottom: 3rem; /* pb-12 */
}

.hero {
    /* Tailwind картка (bg-white, shadow-xl, rounded-2xl) */
    /* Використовуємо чисто білий/контрастний фон відносно загального фону */
    background-color: color-mix(in srgb, var(--color-background) 100%, #fff); 
    border-width: 1px;
    border-radius: 1rem; /* rounded-2xl */
    padding: 4rem 2rem; /* py-16 px-8 */
    margin-top: 2rem;
    margin-bottom: 2rem;
    text-align: center;
    /* Велика сучасна тінь */
    box-shadow: 0 20px 25px -5px color-mix(in srgb, var(--color-text) 10%, transparent), 
                0 8px 10px -6px color-mix(in srgb, var(--color-text) 10%, transparent);
}

.hero h2 {
    font-size: 2.25rem; /* text-4xl */
    font-weight: 800; /* font-extrabold */
    letter-spacing: -0.025em; /* tracking-tight */
    line-height: 2.5rem;
    margin: 0;
    color: var(--color-text);
}

/* --- Підвал (Footer) --- */
.site-footer {
    padding-top: 2rem;
    padding-bottom: 2rem;
    border-top-width: 1px;
    background-color: var(--color-background);
}

.site-footer__copyright {
    text-align: center;
    font-size: 0.875rem; /* text-sm */
    color: color-mix(in srgb, var(--color-text) 60%, transparent);
    margin: 0;
}

/* --- Адаптивність (Responsive) --- */
@media (min-width: 640px) { /* sm */
    .hero h2 {
        font-size: 3rem; /* text-5xl */
        line-height: 1;
    }
}

@media (max-width: 768px) { /* md */
    .site-header__nav {
        display: none;
    }
    
    .site-button {
        padding: 0.375rem 0.75rem; /* px-3 py-1.5 */
        font-size: 0.75rem; /* text-xs */
    }
    
    .hero {
        padding: 2.5rem 1rem;
    }
}

/* ========================================================
   БАЗОВІ НАЛАШТУВАННЯ КОНТЕЙНЕРА
   ======================================================== */
.offers-container {
    display: flex;
    flex-direction: column;
    gap: 16px;
    max-width: 1280px; 
    margin: 0 auto;
    font-family: inherit;
    color: var(--color-text);
}

/* ========================================================
   КАРТКА ОФЕРА (МОБІЛЬНИЙ ВИГЛЯД)
   ======================================================== */
.offer-card {
    background-color: var(--color-background);
    border-radius: 12px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    border: 1px solid rgba(0, 0, 0, 0.05);
    padding: 24px 16px 16px; 
    position: relative;
    display: flex;
    flex-direction: column; /* Вертикально на мобільному */
    align-items: center;
    text-align: center;
    gap: 16px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    overflow: hidden;
}

.offer-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

/* ========================================================
   БЕЙДЖ ПОЗИЦІЇ
   ======================================================== */
.offer-position {
    position: absolute;
    top: 0;
    left: 0;
    background-color: var(--color-secondary); 
    color: #ffffff;
    font-weight: 800;
    font-size: 14px;
    padding: 6px 16px;
    border-bottom-right-radius: 12px;
    z-index: 2;
    box-shadow: 2px 2px 5px rgba(0,0,0,0.1);
}

.offer-card:nth-child(1) .offer-position { background-color: #FFB703; color: #fff; }
.offer-card:nth-child(2) .offer-position { background-color: #9CA3AF; color: #fff; }
.offer-card:nth-child(3) .offer-position { background-color: #CD7F32; color: #fff; }

/* ========================================================
   ЛОГОТИП
   ======================================================== */
.offer-logo {
    width: 140px;
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
}

.offer-logo img {
    max-width: 100%;
    max-height: 100%;
    border-radius: 8px;
    object-fit: contain; 
}

/* ========================================================
   ТЕКСТОВА ІНФОРМАЦІЯ (Назва + Бонус)
   ======================================================== */
.offer-info {
    flex: 1; /* Займає весь вільний простір на ПК */
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.offer-name {
    margin: 0;
    font-size: 20px;
    color: var(--color-text);
    font-weight: 800;
}

.offer-bonus {
    margin: 0;
    font-size: 15px;
    color: var(--color-text);
    opacity: 0.85;
    font-weight: 600;
    line-height: 1.4;
}

/* ========================================================
   БЛОК РЕЙТИНГУ (Окрема колонка)
   ======================================================== */
.offer-rating-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 16px;
    background: rgba(245, 158, 11, 0.05); /* Дуже легкий жовтий фон */
    border-radius: 8px;
}

.rating-stars {
    font-size: 16px;
}

.rating-score {
    font-size: 16px;
    font-weight: 800;
    color: #F59E0B; /* Жовтий колір для цифр */
}

/* ========================================================
   КНОПКИ
   ======================================================== */
.offer-actions {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.btn {
    display: block;
    width: 100%;
    box-sizing: border-box;
    text-decoration: none;
    text-align: center;
    padding: 14px 20px;
    border-radius: 8px;
    font-weight: 700;
    font-size: 16px;
    text-transform: uppercase;
    transition: all 0.2s;
    color: #ffffff; 
}

.btn-primary { background-color: var(--color-primary); }
.btn-primary:hover { filter: brightness(0.9); transform: translateY(-1px); }

/* ========================================================
   ДЕКСТОПНА ВЕРСІЯ (ПК та Планшети від 768px)
   ======================================================== */
@media (min-width: 768px) {
    .offer-card {
        flex-direction: row; /* Вишикувати колонками */
        text-align: left;
        align-items: center;
        padding: 24px 24px 24px 30px; 
        gap: 20px; /* Відступ між колонками */
    }

    .offer-logo {
        margin-top: 0; 
        flex-shrink: 0; 
    }

    /* Налаштування для нової колонки рейтингу */
    .offer-rating-box {
        flex-shrink: 0;
        min-width: 120px; /* Фіксована ширина колонки */
        border-left: 1px solid rgba(0,0,0,0.05); /* Легкий роздільник зліва */
        border-right: 1px solid rgba(0,0,0,0.05); /* Легкий роздільник справа */
        border-radius: 0;
        background: transparent; /* На ПК фон прибираємо, залишаємо лінії */
        padding: 0 20px;
    }

    .offer-actions {
        width: auto;
        min-width: 200px;
        flex-shrink: 0;
    }

    .btn {
        width: auto;
    }

    .offer-name {
        font-size: 22px;
    }
}