:root {
    /* ProSport brand palette, taken from the logo: cyan-blue lettering. */
    --brand-primary: #0396D9;
    --brand-primary-dark: #02729F;
    --brand-primary-soft: #E6F5FC;
    --brand-accent: #D62B1F;        /* prices, sale badges, discounts */
    --brand-accent-dark: #A81F16;
    --brand-navy: #0D2B3E;          /* pre-header / footer */
    --primary-black: #1a1a1a;
    --primary-white: #ffffff;
    --light-bg: #f5f7f9;
    --muted-grey: #6c757d;
    --radius: 10px;
    /* Backward-compat aliases used by shared templates / admin-entered HTML. */
    --brand-red: var(--brand-primary);
    --brand-red-dark: var(--brand-primary-dark);
    --primary-blue: var(--brand-primary);
    --primary-yellow: var(--brand-primary);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background-color: var(--primary-white);
    color: var(--primary-black);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}
a { color: var(--brand-primary-dark); }

/* Pre-header */
.pre-header {
    background-color: var(--brand-navy);
    color: var(--primary-white);
    padding: 7px 0;
    font-size: 13.5px;
}
.pre-header a {
    color: #8fd3f5;
    text-decoration: none;
}
.pre-header a:hover {
    color: var(--primary-white);
}
.pre-header .ph-icon {
    font-size: 16px;
    color: var(--brand-primary);
}
.pre-header .ph-text,
.pre-header .ph-phone,
.pre-header .ph-email {
    white-space: nowrap;
}
.pre-header .ph-text {
    overflow: hidden;
    text-overflow: ellipsis;
}
/* On small screens the e-mail goes first (it is repeated in the footer and on
   the contact page), then the location text shrinks. */
@media (max-width: 767.98px) {
    .pre-header .ph-email,
    .pre-header .ph-icon-mail {
        display: none;
    }
}
@media (max-width: 575.98px) {
    .pre-header { font-size: 11px; }
    .pre-header .ph-icon { font-size: 13px; }
    .pre-header .ph-left { min-width: 0; margin-right: .5rem; }
}

/* Header */
.navbar {
    background-color: var(--primary-white);
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    padding: 10px 0;
}
.navbar-brand img {
    height: 60px;
    width: auto;
}
@media (max-width: 575.98px) {
    .navbar-brand img { height: 48px; }
}
.nav-link {
    color: var(--primary-black) !important;
    font-weight: 500;
}
.nav-link:hover,
.nav-link.active {
    color: var(--brand-primary) !important;
}
@media (min-width: 992px) {
    .navbar-nav .nav-link { white-space: nowrap; }
}
/* Small laptops: 5 menu links + search + logo must share one row. */
@media (min-width: 992px) and (max-width: 1199.98px) {
    .navbar-nav .nav-link { font-size: 14px; padding-left: .45rem !important; padding-right: .45rem !important; }
    .navbar-brand img { height: 50px; }
    .header-search { width: 170px; }
}

/* ------------------------------------------------------------------ */
/* Home hero: category menu + product carousel + two tiles             */
/* ------------------------------------------------------------------ */
.home-hero {
    padding: 24px 0 8px;
    background: linear-gradient(180deg, var(--brand-primary-soft) 0%, #fff 100%);
}

.hero-cats {
    position: relative;
    background: #fff;
    border: 1px solid #e3e8ec;
    border-radius: var(--radius);
    height: 100%;
    z-index: 5;
}
.hero-cats-head {
    display: flex;
    align-items: center;
    gap: 8px;
    background: var(--brand-primary);
    color: #fff;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    font-size: 14px;
    padding: 12px 16px;
    border: 0;
    border-radius: var(--radius) var(--radius) 0 0;
}
button.hero-cats-head { border-radius: var(--radius); }
button.hero-cats-head[aria-expanded="true"] { border-radius: var(--radius) var(--radius) 0 0; }
.hero-cats-list {
    list-style: none;
    margin: 0;
    padding: 6px 0;
}
.hc-item { position: relative; }
.hc-link {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 16px;
    color: #243240;
    text-decoration: none;
    font-weight: 600;
    font-size: 14.5px;
    border-left: 3px solid transparent;
    transition: background-color .15s, color .15s, border-color .15s;
}
.hc-icon { font-size: 20px; color: var(--brand-primary); }
.hc-caret { margin-left: auto; font-size: 18px; color: #9aa7b2; }
.hc-item + .hc-item > .hc-link { border-top: 1px solid #f0f3f5; }
.hc-item:hover > .hc-link,
.hc-item:focus-within > .hc-link {
    background: var(--brand-primary-soft);
    color: var(--brand-primary-dark);
    border-left-color: var(--brand-primary);
}
.hc-all .hc-link { color: var(--brand-primary-dark); }

.hc-sub {
    list-style: none;
    margin: 0;
    padding: 0 0 6px 46px;
}
.hc-sub a {
    display: block;
    padding: 6px 0;
    color: #4a5a68;
    text-decoration: none;
    font-size: 14px;
}
.hc-sub a:hover { color: var(--brand-primary); }

/* Desktop: sub-categories open as a flyout panel over the carousel. */
@media (min-width: 992px) {
    .hc-sub {
        display: none;
        position: absolute;
        top: -7px;
        left: 100%;
        min-width: 260px;
        padding: 12px 0;
        background: #fff;
        border: 1px solid #e3e8ec;
        border-radius: var(--radius);
        box-shadow: 0 12px 28px rgba(13, 43, 62, .14);
    }
    .hc-item:hover > .hc-sub,
    .hc-item:focus-within > .hc-sub { display: block; }
    .hc-sub a { padding: 8px 20px; }
    .hc-sub a:hover { background: var(--brand-primary-soft); }
    .hc-sub-title a {
        font-weight: 700;
        color: var(--brand-primary-dark);
        text-transform: uppercase;
        font-size: 12.5px;
        letter-spacing: .5px;
        border-bottom: 1px solid #f0f3f5;
        margin-bottom: 4px;
    }
}
/* Mobile / tablet: the list is a collapsible panel; sub-categories inline. */
@media (max-width: 991.98px) {
    .hero-cats { height: auto; }
    .hc-caret { display: none; }
}

.hero-carousel {
    background: #fff;
    border: 1px solid #e3e8ec;
    border-radius: var(--radius);
    overflow: hidden;
    min-height: 380px;
}
.hero-slide {
    display: flex;
    align-items: stretch;
    height: 100%;
    min-height: 380px;
}
.hero-slide-img {
    flex: 0 0 52%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    padding: 20px;
}
.hero-slide-img img {
    max-width: 100%;
    max-height: 340px;
    object-fit: contain;
}
.hero-slide-img .img-placeholder { width: 100%; height: 100%; min-height: 300px; }
.hero-slide-body {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 28px 40px 44px 12px;
}
.hero-slide-cat {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--brand-primary);
    margin-bottom: 8px;
}
.hero-slide-title {
    font-size: 1.6rem;
    font-weight: 800;
    line-height: 1.2;
    color: var(--primary-black);
    text-decoration: none;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.hero-slide-title:hover { color: var(--brand-primary-dark); }
.hero-slide-price {
    margin-top: 14px;
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--brand-accent);
}
.hero-slide-price del {
    font-size: 1rem;
    color: #8a96a0;
    font-weight: 400;
    margin-right: 6px;
}
.hero-carousel .carousel-indicators { margin-bottom: .6rem; }
.hero-carousel .carousel-indicators [data-bs-target] {
    width: 22px; height: 4px; border-radius: 2px;
    background-color: var(--brand-primary);
}
.hero-carousel .carousel-control-prev,
.hero-carousel .carousel-control-next { width: 42px; }

@media (max-width: 767.98px) {
    .hero-carousel, .hero-slide { min-height: 0; }
    .hero-slide { flex-direction: column; }
    .hero-slide-img { flex-basis: auto; height: 230px; padding: 14px; }
    .hero-slide-img img { max-height: 200px; }
    .hero-slide-img .img-placeholder { min-height: 200px; }
    .hero-slide-body { padding: 8px 22px 44px; text-align: center; align-items: center; }
    .hero-slide-title { font-size: 1.25rem; }
}

.hero-tile {
    position: relative;
    flex: 1 1 0;
    display: flex;
    align-items: center;
    gap: 14px;
    min-height: 182px;
    padding: 34px 16px 16px;
    background: #fff;
    border: 1px solid #e3e8ec;
    border-radius: var(--radius);
    text-decoration: none;
    color: inherit;
    transition: box-shadow .2s, transform .2s;
}
.hero-tile:hover {
    box-shadow: 0 10px 22px rgba(13, 43, 62, .10);
    transform: translateY(-2px);
}
.hero-tile-label {
    position: absolute;
    top: 10px;
    left: 12px;
    font-size: 11.5px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .5px;
    color: #fff;
    background: var(--brand-accent);
    padding: 3px 8px;
    border-radius: 4px;
}
.hero-tile-img {
    flex: 0 0 42%;
    height: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
}
.hero-tile-img img { max-width: 100%; max-height: 130px; object-fit: contain; }
.hero-tile-img .img-placeholder { width: 100%; height: 100%; }
.hero-tile-img .img-placeholder span { display: none; }
.hero-tile-body { display: flex; flex-direction: column; min-width: 0; }
.hero-tile-title {
    font-weight: 700;
    font-size: .98rem;
    line-height: 1.25;
    color: var(--primary-black);
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.hero-tile-price {
    margin-top: 8px;
    font-weight: 800;
    color: var(--brand-accent);
}
.hero-tile-price del { display: block; font-size: .8rem; font-weight: 400; color: #8a96a0; }

/* Store banner */
.home-banner-wrap { padding: 16px 0 8px; }
.home-banner {
    display: block;
    width: 100%;
    height: auto;
    border-radius: var(--radius);
}
@media (max-width: 575.98px) {
    .home-banner { height: 110px; object-fit: cover; }
}

/* ------------------------------------------------------------------ */
/* Product cards / carousels                                          */
/* ------------------------------------------------------------------ */
.featured-products {
    padding: 60px 0;
    background-color: var(--light-bg);
    overflow-x: clip;   /* the carousel arrows sit just outside the container */
}
/* Below 1200px there is no room beside the container: keep the arrows inside. */
@media (max-width: 1199.98px) {
    #featuredCarousel .carousel-control-prev { left: -12px !important; width: 36px !important; }
    #featuredCarousel .carousel-control-next { right: -12px !important; width: 36px !important; }
}
.product-card {
    background: var(--primary-white);
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
}
.product-card .img-wrapper {
    position: relative;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    overflow: hidden;
    background-color: #fff;
    display: block;
}
.product-card .img-wrapper > img,
.product-card .img-wrapper > .img-placeholder {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}
.product-card .img-wrapper > img {
    object-fit: contain; /* Keeps ratio without breaking/stretching */
    padding: 10px;
}
.product-card .card-body {
    padding: 20px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}
.product-card .product-title {
    font-size: 1.05rem;
    font-weight: 600;
    color: var(--primary-black);
    text-decoration: none;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.product-card .product-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--brand-accent);
    margin-bottom: 15px;
    margin-top: auto;
}
.product-card .product-price del {
    font-size: 0.9rem;
    color: #6c757d;
    font-weight: 400;
    margin-right: 8px;
}

/* Discount badges */
.badge-sale {
    position: absolute;
    top: 10px;
    left: 10px;
    z-index: 2;
    background: var(--brand-accent);
    color: #fff;
    font-weight: 700;
    font-size: 12.5px;
    padding: 3px 8px;
    border-radius: 4px;
}
.badge-sale-inline {
    display: inline-block;
    vertical-align: middle;
    background: var(--brand-accent);
    color: #fff;
    font-size: .8rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 4px;
    margin-right: 8px;
}

/* Placeholder for products still without a photo */
.img-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: repeating-linear-gradient(45deg, #f7fafc, #f7fafc 12px, #f1f5f8 12px, #f1f5f8 24px);
    color: #9aa7b2;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .5px;
}
.img-placeholder img {
    width: 34%;
    max-width: 90px;
    height: auto;
    opacity: .28;
    padding: 0 !important;
    position: static !important;
    filter: grayscale(100%);
}

.btn.checkout {
    background-color: var(--brand-primary);
    color: var(--primary-white);
    font-weight: 600;
    border: none;
    padding: 10px 20px;
    border-radius: 4px;
    transition: background-color 0.2s;
    text-transform: uppercase;
    font-size: 14px;
}
.btn.checkout:hover {
    background-color: var(--brand-primary-dark);
    color: var(--primary-white);
}

/* Carousel Overrides */
.carousel-control-prev, .carousel-control-next {
    width: 5%;
    color: var(--primary-black);
}
.carousel-control-prev-icon, .carousel-control-next-icon {
    filter: invert(1);
}

/* Footer */
footer {
    background-color: var(--brand-navy);
    color: var(--primary-white);
    padding: 50px 0 20px;
    margin-top: auto;
}
footer a {
    color: rgba(255,255,255,0.75);
    text-decoration: none;
}
footer a:hover {
    color: var(--primary-white);
}
.bottom-footer {
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    margin-top: 30px;
    font-size: 14px;
    text-align: center;
    color: rgba(255,255,255,0.55);
}

/* Footer social icons */
.footer-social-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background-color: rgba(255,255,255,0.1);
    color: rgba(255,255,255,0.85) !important;
    transition: background-color 0.2s, color 0.2s, transform 0.2s;
}
.footer-social-icon:hover {
    background-color: var(--brand-primary);
    color: var(--primary-white) !important;
    transform: translateY(-2px);
}
/* Keep the Facebook page embed inside its column on all screens */
.footer-fb-embed {
    max-width: 100%;
    overflow: hidden;
}
.footer-fb-embed iframe {
    max-width: 100% !important;
}

/* Checkout Form */
.checkout-form-wrapper {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.btn#purchase {
    background-color: var(--brand-primary);
    color: var(--primary-white);
    font-weight: 600;
    padding: 15px 30px;
    font-size: 18px;
    border-radius: 6px;
    border: none;
    width: 100%;
}
.btn#purchase:hover {
    background-color: var(--brand-primary-dark);
}

/* Product page */
.product-gallery-main {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 400px;
    border: 1px solid #eef1f3;
    border-radius: var(--radius);
    background: #fff;
}
.product-gallery-main .img-placeholder { width: 100%; min-height: 400px; border-radius: var(--radius); }
.product-description img {
    max-width: 100%;
    height: auto;
}
.product-description img.emoji {
    display: inline !important;
    border: none !important;
    box-shadow: none !important;
    height: 1em !important;
    width: 1em !important;
    margin: 0 0.07em !important;
    vertical-align: -0.1em !important;
    background: none !important;
    padding: 0 !important;
}

/* Header search */
.header-search { width: 260px; }
.header-search .input-group {
    border: 1px solid #e3e6ea;
    border-radius: 6px;
    overflow: hidden;
    background: #fff;
}
.header-search .input-group-text {
    border: 0;
    background: #fff;
}
.header-search .form-control {
    border: 0;
    box-shadow: none;
    font-size: 14px;
}
.header-search .form-control:focus {
    box-shadow: none;
}
.header-search .form-control::placeholder {
    color: #b0b0b0;
}
@media (max-width: 991.98px) {
    .header-search { width: 100%; }
}

/* Sub-categories in the shop sidebar (slug "parent/child") sit under their parent */
.shop-sidebar .cat-list .cat-child > a {
    padding-left: 16px;
    font-size: 0.95em;
}
.shop-sidebar .cat-list .cat-child > a::before {
    content: "—";
    margin-right: 6px;
    color: var(--muted-grey);
}

/* ------------------------------------------------------------------ */
/* Известувања за риболов (news)                                      */
/* ------------------------------------------------------------------ */
.news-hero {
    background: linear-gradient(120deg, var(--brand-navy) 0%, #11506f 100%);
    color: #fff;
    padding: 44px 0 38px;
}
.news-hero h1 { font-weight: 800; margin: 0; }
.news-hero p { color: rgba(255,255,255,.75); margin: 8px 0 0; }
.news-card {
    display: flex;
    flex-direction: column;
    height: 100%;
    background: #fff;
    border: 1px solid #e8edf0;
    border-radius: var(--radius);
    overflow: hidden;
    text-decoration: none;
    color: inherit;
    transition: box-shadow .2s, transform .2s;
}
.news-card:hover { box-shadow: 0 10px 22px rgba(13,43,62,.10); transform: translateY(-3px); color: inherit; }
.news-card-img { aspect-ratio: 16 / 9; background: var(--brand-primary-soft); overflow: hidden; }
.news-card-img img { width: 100%; height: 100%; object-fit: cover; }
.news-card-img .img-placeholder { width: 100%; height: 100%; }
.news-card-img .img-placeholder span { display: none; }
.news-card-body { padding: 18px 20px 22px; display: flex; flex-direction: column; flex: 1; }
.news-date { font-size: 12.5px; color: var(--brand-primary-dark); font-weight: 600; text-transform: uppercase; letter-spacing: .5px; }
.news-card-title { font-size: 1.15rem; font-weight: 700; margin: 6px 0 8px; color: var(--primary-black); }
.news-card-excerpt { color: #56636e; font-size: .95rem; margin-bottom: 14px; }
.news-more { margin-top: auto; font-weight: 600; color: var(--brand-primary-dark); }
.post-cover { width: 100%; max-height: 440px; object-fit: cover; border-radius: var(--radius); }
.page-content h2, .post-content h2 { margin-top: 1.5em; margin-bottom: .6em; font-weight: 700; }
.page-content h3, .post-content h3 { margin-top: 1.2em; margin-bottom: .5em; font-weight: 600; }
.page-content p, .post-content p { margin-bottom: 1em; }
.page-content img, .post-content img { max-width: 100%; height: auto; border-radius: 6px; margin: 0.5em 0; }
.page-content iframe, .post-content iframe { max-width: 100%; }
.page-content hr, .post-content hr { margin: 1.8em 0; border: 0; border-top: 1px solid #e3e6ea; }
.page-content .row, .post-content .row { margin-bottom: 1em; }
.page-content ul, .page-content ol, .post-content ul, .post-content ol { margin-bottom: 1em; }
