:root {
    /* Premium Design System */
    /* Typography */
    --at-font-heading: "Outfit", sans-serif;
    --at-font-body: "Inter", sans-serif;

    /* Colors */
    --at-primary: #e73f29;
    --at-primary-dark: #b93321;
    --at-primary-light: #f4b4ae;
    --at-accent: #ffb703;
    --at-accent-hover: #f0a500;

    /* Neutrals */
    --at-bg-body: #f9fafb;
    --at-bg-soft: #f1f5f9;
    --at-border: rgba(37, 36, 36, 0.08);
    --at-text: #252424;
    --at-text-muted: #64748b;

    /* Effects */
    --at-shadow-sm: 0 2px 8px rgba(37, 36, 36, 0.04);
    --at-shadow: 0 12px 40px -8px rgba(37, 36, 36, 0.12);
    --at-shadow-hover: 0 20px 50px -10px rgba(37, 36, 36, 0.18);
    --at-glass-bg: rgba(255, 255, 255, 0.85);
    --at-glass-border: rgba(255, 255, 255, 0.3);
    --at-blur: blur(16px);

    /* Dimensions & Radius */
    --at-radius-lg: 24px;
    --at-radius-md: 16px;
    --at-radius-sm: 12px;
    --at-input-height: 64px;
}

body {
    font-family: var(--at-font-body);
    color: var(--at-text);
    background: var(--at-bg-body);
    -webkit-font-smoothing: antialiased;
}

/* Typography & Utilities */
h1,
h2,
h3,
h4,
h5,
h6,
.at-brand,
.at-section-title {
    font-family: var(--at-font-heading);
}
.at-brand {
    font-weight: 700;
    font-size: 1.25rem;
    letter-spacing: -0.03em;
}
.at-brand span:first-child {
    color: var(--at-text);
}
.at-brand span:last-child {
    color: var(--at-primary);
}
.at-section {
    padding: 64px 0;
}
.at-section-title {
    font-weight: 700;
    color: var(--at-primary);
    letter-spacing: -0.02em;
}
.container-xxl.at-container {
    max-width: 1280px;
}

/* Navbar */
.at-navbar {
    height: 72px;
    border-bottom: 1px solid var(--at-border);
    background: rgba(255, 255, 255, 0.98); /* Increased opacity */
    /* backdrop-filter: var(--at-blur); REMOVED for performance */
}

/* Components */
.at-pill {
    border: 1px solid var(--at-border);
    border-radius: 999px;
    padding: 0.4rem 0.85rem;
    background: #fff;
    font-size: 0.9rem;
    font-weight: 500;
    color: var(--at-text-muted);
    transition: all 0.2s;
}
.at-pill:hover {
    border-color: var(--at-primary-light);
    color: var(--at-primary);
    background: #fff;
}

.at-card {
    border: 1px solid var(--at-border);
    border-radius: var(--at-radius-md);
    box-shadow: var(--at-shadow-sm);
    transition: all 0.25s cubic-bezier(0.2, 0.8, 0.2, 1);
    background: #fff;
    overflow: hidden;
}
.at-card:hover {
    transform: translateY(-4px) scale(1.01);
    box-shadow: var(--at-shadow-hover);
    border-color: rgba(37, 36, 36, 0.15);
}
.at-soft {
    background: var(--at-bg-soft);
    border: 1px solid var(--at-border);
    border-radius: var(--at-radius-md);
}

/* Inputs & Form Elements */
.at-input {
    border: 1px solid var(--at-border);
    border-radius: 14px;
    height: var(--at-input-height);
    display: flex;
    align-items: center;
    padding: 0 0.9rem;
    background: #fff;
    box-shadow: var(--at-shadow-sm);
    transition: all 0.2s;
}
.at-input:focus-within {
    border-color: var(--at-primary-light);
    box-shadow: 0 0 0 3px rgba(231, 63, 41, 0.1);
}
.at-input .form-control,
.at-input .form-select {
    border: none !important;
    box-shadow: none !important;
    padding-left: 0.25rem;
    font-weight: 500;
    color: var(--at-text);
}

/* Tabs */
.at-tabs .nav-link,
.at-cat-tabs .nav-link {
    border: none;
    border-bottom: 2px solid transparent;
    border-radius: 0;
    font-weight: 600;
    color: var(--at-text-muted);
}
.at-tabs .nav-link {
    font-family: var(--at-font-heading);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 0.9rem;
}
.at-cat-tabs .nav-link {
    padding: 0.6rem 0.9rem;
    /* at-cat-tabs uses text-muted default but bold weight */
    font-weight: 700;
    color: var(--at-muted);
}
.at-tabs .nav-link.active {
    color: var(--at-primary);
    border-bottom-color: var(--at-accent);
    background: transparent;
}
.at-cat-tabs .nav-link.active {
    color: var(--at-text);
    border-bottom-color: var(--at-primary);
}

/* Hero & Search Card */
.at-hero {
    position: relative;
    color: #fff;
    min-height: 400px;
    display: flex;
    align-items: center;
    padding-top: 40px;
    background: linear-gradient(300deg, rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.6)),
        url("img/kurja.jpg") center/cover no-repeat;
}
.at-hero::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(
        circle at 50% 20%,
        rgba(30, 28, 28, 0.3),
        rgba(0, 0, 0, 0.4)
    );
    pointer-events: none;
}
.at-hero .container,
.at-hero .container-xxl {
    position: relative;
    z-index: 1;
}
.at-hero h1 {
    font-family: var(--at-font-heading);
    letter-spacing: -0.02em;
    font-weight: 700;
    line-height: 1.1;
    text-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}
.at-hero p {
    color: rgba(255, 255, 255, 0.85);
    max-width: 780px;
    margin-inline: auto;
}

.at-search-card {
    border-radius: var(--at-radius-lg);
    box-shadow: var(--at-shadow);
    border: 1px solid var(--at-glass-border);
    background: rgba(255, 255, 255, 0.95);
    /* backdrop-filter: var(--at-blur); REMOVED for performance */
    color: var(--at-text);
    margin-top: 20px;
}

/* Promo Banner */
.at-promo {
    background: var(--at-primary-dark);
    color: #fff;
}
.at-promo a {
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    border-bottom: 1px solid rgba(255, 255, 255, 0.35);
}
.at-promo a:hover {
    border-bottom-color: rgba(255, 255, 255, 0.85);
}

/* Badges */
.at-badge-accent {
    background: rgba(255, 247, 230, 0.95); /* More opaque */
    color: #b45309; /* Darker text for contrast */
    border: 1px solid rgba(247, 181, 0, 0.5);
    font-weight: 700;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}
.at-rating-badge {
    border-radius: 999px;
    font-weight: 800;
    padding: 0.25rem 0.5rem;
}
.at-rating-high {
    background: rgba(16, 185, 129, 0.14);
    color: #0f766e;
    border: 1px solid rgba(16, 185, 129, 0.25);
}
.at-rating-mid {
    background: rgba(59, 130, 246, 0.14);
    color: #1d4ed8;
    border: 1px solid rgba(59, 130, 246, 0.22);
}
.at-rating-low {
    background: rgba(245, 158, 11, 0.14);
    color: #92400e;
    border: 1px solid rgba(245, 158, 11, 0.22);
}

/* Footer */
footer {
    border-top: 1px solid var(--at-border);
    background: #fff;
}

/* Bootstrap Overrides / Custom Buttons */
.btn-primary {
    background-color: var(--at-primary);
    border-color: var(--at-primary);
    box-shadow: 0 4px 12px rgba(231, 63, 41, 0.2);
    transition: all 0.2s;
}
.btn-primary:hover,
.btn-primary:active {
    background-color: var(--at-primary-dark);
    border-color: var(--at-primary-dark);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(231, 63, 41, 0.3);
}

/* Timeline Visualization */
.at-timeline-line {
    position: absolute;
    top: 10px;
    bottom: -10px;
    left: 77px; /* Adjusted for time label width + gap */
    width: 2px;
    background-color: var(--at-border);
    z-index: 0;
}
.at-timeline-item:last-child .at-timeline-line {
    display: none;
}
.at-timeline-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #fff;
    border: 2px solid var(--at-text-muted);
    z-index: 1;
    flex-shrink: 0;
}
.at-timeline-content {
    flex-grow: 1;
}
.at-timeline-time {
    color: var(--at-text);
}
.rotate-45 {
    display: inline-block;
    transform: rotate(45deg);
}

/* Deal Hero specifics */
.at-hero-deal::after {
    background: linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.9) 0%,
        rgba(0, 0, 0, 0) 50%
    );
}

.backdrop-blur {
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

/* Range Input Styling (Webkit only for demo) */
input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    background: transparent;
}
input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    height: 20px;
    width: 20px;
    border-radius: 50%;
    background: var(--at-primary);
    border: 4px solid #fff;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    margin-top: -8px;
}
input[type="range"]::-webkit-slider-runnable-track {
    width: 100%;
    height: 4px;
    cursor: pointer;
    background: var(--at-border);
    border-radius: 2px;
}
input[type="range"]:focus::-webkit-slider-runnable-track {
    background: var(--at-primary-light);
}

/* Pagination Overrides */
.page-link {
    box-shadow: none !important;
}
