/**
 * Custom Styles for Browar Website
 * Additional styling for age verification, beer slider, and Facebook feed
 */

/* Nadpisanie Bootstrap — Lato jako jedyna czcionka */
.tooltip,
.popover {
    font-family: 'Lato', sans-serif;
}

/* ================================================
   KOLORYSTYKA — JASNA Z MARMUROWYM TŁEM
   ================================================ */

/*
 * Marmurowe tło — PLACEHOLDER.
 * Gdy klient dostarczy zdjęcie, zamień background-image poniżej na:
 *   background-image: url('assets/images/marble-bg.jpg');
 *   background-size: cover;
 *   background-attachment: fixed;
 */
html, body {
    background-color: #f8f5ef;
}

/* Podmenu na mobile — wcięcie */
@media (max-width: 840px) {
    .navbar-nav .open .dropdown-menu > li > a {
        padding-left: 60px !important;
    }
}

/* Sekcje z białym tłem — ciepły odcień zamiast czystej bieli */
.bg-white {
    background-color: #faf8f4 !important;
    background-image:
        radial-gradient(ellipse at 10% 40%, rgba(210, 195, 170, 0.18) 0%, transparent 55%),
        radial-gradient(ellipse at 90% 20%, rgba(205, 190, 165, 0.12) 0%, transparent 45%),
        radial-gradient(ellipse at 55% 90%, rgba(215, 200, 175, 0.14) 0%, transparent 50%);
}

/* ================================================
   AGE VERIFICATION
   ================================================ */

.age-verification-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(30, 25, 15, 0.82);
    z-index: 99999;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.age-verification-overlay.active {
    display: flex;
    opacity: 1;
    animation: fadeIn 0.3s ease-in;
}

.age-verification-overlay.active .age-verification-modal {
    animation: scaleIn 0.4s ease-out;
}

.age-verification-modal {
    background: #faf8f4;
    padding: 50px;
    border-radius: 10px;
    text-align: center;
    max-width: 480px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.25);
}

.age-modal-logo { margin-bottom: 28px; }
.age-modal-logo img { max-width: 180px; height: auto; }

.age-verification-modal h2 {
    font-size: 26px;
    margin-bottom: 32px;
    color: #2a2a2a;
    text-transform: none;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.age-verification-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
}

.age-btn {
    padding: 14px 40px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    position: relative;
    overflow: hidden;
}

.age-btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.age-btn:hover::before { width: 300px; height: 300px; }

.age-btn-yes { background: #c9a227; color: #fff; }
.age-btn-yes:hover { background: #d4af37; transform: translateY(-2px); }
.age-btn-no { background: #999; color: #fff; }
.age-btn-no:hover { background: #777; transform: translateY(-2px); }

@media (max-width: 768px) {
    .age-verification-modal { padding: 30px 20px; }
    .age-btn { padding: 12px 30px; font-size: 14px; }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-10px); }
    20%, 40%, 60%, 80% { transform: translateX(10px); }
}

.shake-animation { animation: shake 0.5s; }

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes scaleIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

/* ================================================
   BEER SLIDER
   ================================================ */

.beer-slide-content {
    display: flex;
    align-items: center;
    gap: 30px;
    max-width: 1200px;
    margin: 0 auto;
    min-height: 400px;
    padding: 20px;
}

.beer-slide-image {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    border-radius: 10px;
}

.beer-slide-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, rgba(0,0,0,0.1) 0%, rgba(0,0,0,0) 100%);
    z-index: 1;
    pointer-events: none;
}

.beer-slide-image img {
    width: 60%;
    height: auto;
    border-radius: 10px;
    transition: transform 0.5s ease;
}

.beer-slide-image:hover img { transform: scale(1.05); }

.beer-slide-description {
    flex: 1;
    color: #fff;
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.beer-slide-description h3 {
    font-size: 32px;
    color: #fff;
    position: relative;
    padding-bottom: 15px;
    margin-bottom: 25px;
}

.beer-slide-description h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, #f39c12 0%, #e74c3c 100%);
}

.beer-slide-description p {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 15px;
    opacity: 0.9;
    transition: opacity 0.3s ease;
}

.beer-slide-description p:hover { opacity: 1; }

@media (max-width: 991px) {
    .beer-slide-content {
        flex-direction: column;
        min-height: auto;
    }

    .beer-slide-image,
    .beer-slide-description {
        flex: 1 1 100%;
        max-width: 92%;
    }

    .beer-slide-image { margin-bottom: 30px; }
}

@media (max-width: 768px) {
    .beer-slide-content { flex-direction: column; }

    .beer-slide-description h3 { font-size: 24px; }

    .beer-slide-description p { font-size: 14px; }

    .beer-slide-description p:not(:has(strong)) { display: none; }

    .beer-slide-image {
        cursor: pointer;
        position: relative;
    }

    .beer-slide-image::after {
        content: "Kliknij po więcej";
        position: absolute;
        bottom: 10px;
        left: 50%;
        transform: translateX(-50%);
        background: rgba(0, 0, 0, 0.7);
        color: #fff;
        padding: 5px 15px;
        border-radius: 20px;
        font-size: 12px;
    }
}

/* ================================================
   FACEBOOK FEED
   ================================================ */

.facebook-feed-container {
    padding: 50px 0;
    position: relative;
}

.fb-feed-slider {
    position: relative;
    overflow: hidden;
    padding: 20px 0;
}

.fb-feed-wrapper {
    display: flex;
    gap: 30px;
    transition: transform 0.5s ease;
}

.fb-post-item {
    min-width: 350px;
    background: #1a1a1a;
    border-radius: 10px;
    padding: 20px;
    color: #fff;
}

.facebook-feed-container .fb-page {
    display: inline-block;
    margin: 0 auto;
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.fb-page[fb-xfbml-state="loading"] {
    animation: pulse 1.5s ease-in-out infinite;
}

@media (max-width: 768px) {
    .facebook-feed-container .fb-page { max-width: 100% !important; }
    .facebook-feed-container iframe { max-width: 100% !important; }
}

/* ================================================
   BEER MODAL
   ================================================ */

.beer-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.95);
    z-index: 9999;
    overflow-y: auto;
    animation: fadeIn 0.3s ease;
}

.beer-modal.active {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 20px 20px;
}

.beer-modal-close {
    position: fixed;
    top: 15px;
    right: 20px;
    font-size: 40px;
    color: #fff;
    cursor: pointer;
    z-index: 10000;
    line-height: 1;
    transition: transform 0.2s ease;
}

.beer-modal-close:hover { transform: scale(1.2); }

.beer-modal-content {
    color: #fff;
    text-align: center;
    width: 100%;
    max-width: 500px;
}

.beer-modal-content h3 {
    font-size: 28px;
    margin-bottom: 20px;
    color: #f5a623;
}

.beer-modal-content .modal-image {
    width: 70%;
    max-width: 300px;
    height: auto;
    border-radius: 10px;
    margin: 0 auto 25px;
    display: block;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
}

.beer-modal-content p {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 15px;
    text-align: left;
}

.beer-modal-content strong { color: #f5a623; }

/* ================================================
   SCROLL ANIMATIONS — obsługiwane przez template (blocks.js)
   ================================================ */
/* Nie duplikujemy tutaj — template sam zarządza scroll-animated-from-bottom */

/* ================================================
   ADDITIONAL NAVIGATION ENHANCEMENTS
   ================================================ */

.navigation-main {
    transition: all 0.3s ease;
}

.navigation-main.sticky {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Active menu item highlight */
.navigation-items li a.active {
    color: #f39c12 !important;
    position: relative;
}

.navigation-items li a.active::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 2px;
    background: #f39c12;
}

/* ================================================
   LOADING IMPROVEMENTS
   ================================================ */

#page-loader {
    background: #000;
    z-index: 999999;
}

#page-loader .css-spinner {
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: #f39c12;
}

/* ================================================
   CUSTOM UTILITY CLASSES
   ================================================ */

.text-gradient {
    background: linear-gradient(135deg, #f39c12 0%, #e74c3c 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hover-lift {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.hover-lift:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

/* ================================================
   PRINT STYLES
   ================================================ */

@media print {
    .age-verification-overlay,
    .navigation-main,
    .scroll-top,
    #page-loader {
        display: none !important;
    }
}

/* ================================================
   ACCESSIBILITY IMPROVEMENTS
   ================================================ */

/* Focus styles for keyboard navigation */
a:focus,
button:focus,
input:focus {
    outline: 2px solid #f39c12;
    outline-offset: 2px;
}

/* Skip to content link for screen readers */
.skip-to-content {
    position: absolute;
    top: -40px;
    left: 0;
    background: #f39c12;
    color: white;
    padding: 8px;
    text-decoration: none;
    z-index: 100000;
}

.skip-to-content:focus {
    top: 0;
}

/* ================================================
   DARK MODE SUPPORT (Optional)
   ================================================ */

@media (prefers-color-scheme: dark) {
    /* Add dark mode styles if needed */
}

/* ================================================
   TYTUŁY SEKCJI — mniejszy odstęp między literkami
   ================================================ */

.header h1,
.header h2 {
    letter-spacing: 0.04em !important;
    font-weight: 700 !important;
}

/* Podtytuły sekcji (np. "Miejsca, gdzie znajdziesz piwa BŁ") — szary kolor */
.header p,
.header span:not(.required) {
    color: #888 !important;
}

/* ================================================
   KONTAKT — WYŁĄCZ CAPS LOCK NA ADRESACH I EMAILACH
   Bloki.css ustawia text-transform: uppercase na wszystkich
   nagłówkach wewnątrz section .header — nadpisujemy dla kontaktu.
   ================================================ */

#contact .header h4,
#contact .header h5 {
    text-transform: none;
}

/* ================================================
   SOCIAL MEDIA — GRAFIKI Z KSIĘGI ZNAKU
   ================================================ */

.social-brand-icon {
    display: block;
    width: 40px;
    height: 40px;
    object-fit: contain;
}

/* ================================================
   KONTAKT — DANE WSPÓLNIKÓW
   ================================================ */

.contact-person-data a {
    color: #3b3d40;
}

.contact-person-data a:hover {
    color: #c9a227;
}

/* ================================================
   KONTAKT — FORMULARZ BEZ TŁA I CIENI
   ================================================ */

#contact .form-container,
#contact .bg-white .form-container {
    background: transparent;
    box-shadow: none;
    padding: 0;
}

#contact .btn-submit {
    background: #c9a227;
    color: #fff;
    border: none;
}

#contact .btn-submit:hover {
    background: #d4af37;
}

/* ================================================
   WSPÓŁPRACA — WYŁĄCZ CAPS LOCK NA TYTULE STRONY
   ================================================ */

#partnership .header h1 {
    text-transform: none;
}

/* ================================================
   KAFELKI WSPÓŁPRACY (CTA na index + wspolpraca.html)
   ================================================ */

/* Smooth scroll dla anchor linków */
html {
    scroll-behavior: smooth;
}

/* Siatka kafelków: 3 w rzędzie na desktop, 1 na mobile */
.cta-tiles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 60px;
}

/* Pojedynczy kafelek */
.cta-tile {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: #12192c;
    border-radius: 16px;
    padding: 44px 32px 36px;
    text-decoration: none;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cta-tile:hover {
    transform: translateY(-6px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.25);
    text-decoration: none;
}

/* Ikona */
.cta-tile-icon {
    font-size: 42px;
    color: #fff;
    margin-bottom: 22px;
    display: block;
}

/* Tytuł kafelka — NIE uppercase */
.cta-tile h3,
.bg-white .cta-tile h3 {
    color: #fff !important;
    font-size: 26px;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: none;
    letter-spacing: 0;
}

/* Podtytuł */
.cta-tile p,
.bg-white .cta-tile p {
    color: #ffffff !important;
    font-size: 14px;
    line-height: 1.6;
    margin-bottom: 32px;
    flex-grow: 1;
}

/* Złoty przycisk */
.cta-tile-btn {
    display: inline-block;
    background: #c9a227;
    color: #fff;
    padding: 13px 30px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.02em;
    transition: background 0.3s ease;
    text-transform: none;
}

.cta-tile:hover .cta-tile-btn {
    background: #d4af37;
}

.cta-tile--has-image {
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
}

.cta-tile--has-image::before {
    content: '';
    position: absolute;
    inset: 0;
    background: rgba(10, 15, 30, 0.58);
    border-radius: inherit;
    pointer-events: none;
}

.cta-tile--has-image > * {
    position: relative;
    z-index: 1;
}

/* Sekcje szczegółowe na wspolpraca.html */
.wspolpraca-section {
    padding: 80px 0;
    border-bottom: 1px solid rgba(0,0,0,0.08);
    scroll-margin-top: 80px; /* offset za nawigację sticky */
    text-align: center;
}

.wspolpraca-section:last-child {
    border-bottom: none;
}

.wspolpraca-section h2 {
    color: #1a1a1a;
    font-size: 36px;
    font-weight: 700;
    margin-bottom: 8px;
    text-transform: none;
}

.wspolpraca-section .section-subtitle {
    color: #888;
    font-size: 16px;
    margin-bottom: 32px;
    display: block;
}

.wspolpraca-section p {
    color: #444;
    font-size: 16px;
    line-height: 1.8;
    max-width: 720px;
    margin: 0 auto 16px;
}

.wspolpraca-contact-box {
    margin-top: 32px;
    padding: 28px 32px;
    background: transparent;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    display: inline-block;
}

.wspolpraca-contact-box p {
    color: #444;
    margin: 0;
    font-size: 15px;
    line-height: 1.9;
}

.wspolpraca-contact-box strong {
    color: #c9a227;
}

/* Offset dla sekcji z anchor — kompensacja sticky nav */
#gastronomia,
#sklepy,
#inne {
    scroll-margin-top: 80px;
}

/* Mobile */
@media (max-width: 991px) {
    .cta-tiles-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        margin-top: 40px;
    }

    .cta-tile {
        padding: 36px 28px 30px;
    }

    .wspolpraca-section h2 {
        font-size: 28px;
    }
}

/* ================================================
   HIGH CONTRAST MODE (Optional)
   ================================================ */

@media (prefers-contrast: high) {
    .age-btn-yes {
        border: 2px solid #000;
    }
    
    .age-btn-no {
        border: 2px solid #000;
    }
}

/* WP: WYSIWYG w info-box — li bez spana */
#label-form .info-box .info-box-content li {
    color: #555 !important;
}

/* WP: klikalne imiona w sekcji O nas */
.founder-trigger {
    color: #2a2a2a;
    font-weight: 700;
    border-bottom: 1px solid #2a2a2a;
    cursor: pointer;
    transition: color 0.2s, border-color 0.2s;
}
.founder-trigger:hover {
    color: #c9a227;
    border-bottom-color: #c9a227;
}
