:root {
    --primary: #050505;
    --secondary: #d4b483;
    --light: #f0f0f0;
    --dark: #1a1a1a;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Raleway', sans-serif;
    color: var(--dark);
    line-height: 1.6;
    background-color: white;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.logo {
    display: flex;
    align-items: center;
    margin-right: 2rem;
    padding: 5px 0;
}

.logo img {
    height: 50px;
    width: auto;
    display: block;
}

/* Formularz kontaktowy */
.contact-container {
    max-width: 100%;
    margin: 0 auto;
    padding: 20px;
    background: #f9f9f9;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    overflow-x: hidden;
}

.contact-form h1, 
.contact-form h2 {
    color: var(--primary);
    margin-bottom: 20px;
}

.form-section {
    margin-bottom: 30px;
    padding: 20px;
    background: white;
    border-radius: 5px;
    box-shadow: 0 0 5px rgba(0,0,0,0.05);
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--dark);
}

.form-control {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    font-family: 'Raleway', sans-serif;
    transition: border-color 0.3s;
}

.form-control:focus {
    border-color: var(--secondary);
    outline: none;
}

textarea.form-control {
    min-height: 100px;
    resize: vertical;
}

.checkbox-group {
    display: flex;
    align-items: center;
}

.checkbox-group input {
    margin-right: 10px;
}

.btn-submit {
    background-color: var(--primary);
    color: var(--light);
    border: none;
    padding: 12px 20px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s;
    width: 100%;
    font-family: inherit; /* <- to powoduje dziedziczenie z body */
}

.btn-submit:hover {
    background-color: var(--secondary);
    color: var(--dark);
}

.quote-results {
    background: #f5f5f5;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 15px;
}

.quote-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
}

.quote-row.total {
    font-weight: bold;
    font-size: 1.1em;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #ddd;
}

.quote-note {
    color: #666;
    font-size: 0.9em;
    font-style: italic;
}

optgroup {
    font-weight: bold;
    font-family: 'Raleway', sans-serif;
}

optgroup option {
    font-weight: normal;
}

#material-image-container {
    margin-top: 10px;
    text-align: center;
}

#material-image {
    max-width: 200px;
    display: none;
    border-radius: 4px;
    border: 1px solid #ddd;
    margin-top: 10px;
}

header {
    background-color: var(--light);
    color: black;
    padding: 1.5rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 2rem;
}

.nav-center {
    display: flex;
    justify-content: center;
    flex: 1;
}

nav ul {
    display: flex;
    justify-content: center;
    list-style: none;
}

nav ul li {
    margin: 0 1.5rem;
}

nav ul li a {
    color: black;
    text-decoration: none;
    font-weight: 600;
    letter-spacing: 1px;
    transition: color 0.3s;
}

nav ul li a:hover {
    color: var(--secondary);
}

/* Hero section with parallax effect */
.hero {
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)), 
                url('img/homepage.jpg') no-repeat center center/cover;
    color: white;
    position: relative;
    overflow: hidden;
    background-attachment: fixed;
}

.hero-content {
    position: relative;
    z-index: 2;
    padding: 0 2rem;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1.5rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
}

.hero p {
    font-size: 1.5rem;
    max-width: 800px;
    margin: 0 auto 2rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

/* About section */
.about-section {
    padding: 5rem 0;
    background-color: white;
}

.about-section h2 {
    text-align: center;
    margin-bottom: 2rem;
    color: var(--primary);
    font-size: 2rem;
}

.about-section p {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    font-size: 1.1rem;
    line-height: 1.8;
}

/* Gallery section */
.gallery-section {
    padding: 5rem 0;
    background-color: var(--light);
}

.gallery-section h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary);
    font-size: 2rem;
}

.gallery-container {
    position: relative;
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
}

.gallery-slider {
    display: flex;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
    width: 100%;
    scrollbar-width: none; /* Firefox */
}

.gallery-slider::-webkit-scrollbar {
    display: none; /* Chrome/Safari */
}

.slide {
    scroll-snap-align: start;
    flex-shrink: 0;
    width: 100%;
    height: 400px;
    margin-right: 20px;
    border-radius: 10px;
    overflow: hidden;
    position: relative;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

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

.gallery-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.7);
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5rem;
    color: var(--primary);
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gallery-arrow:hover {
    background: var(--secondary);
    color: white;
}

.left-arrow {
    left: 20px;
}

.right-arrow {
    right: 20px;
}

/* Features section */
.features-section {
    padding: 5rem 0;
    background-color: white;
}

.features-section h2 {
    text-align: center;
    margin-bottom: 3rem;
    color: var(--primary);
    font-size: 2rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.feature {
    background: var(--light);
    padding: 2rem;
    border-radius: 8px;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.feature:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.feature i {
    font-size: 2.5rem;
    color: var(--secondary);
    margin-bottom: 1.5rem;
}

.feature h3 {
    color: var(--primary);
    margin-bottom: 1rem;
    font-size: 1.3rem;
}

.feature p {
    color: var(--dark);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.page-section {
    max-width: 1200px;
    margin: 3rem auto;
    padding: 0 2rem;
}

.hamburger {
    display: none;
    background-color: var(--light);
    padding: 15px;
    
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--primary);
    margin: 5px 0;
    transition: all 0.3s ease;
}

.mobile-link {
    display: none;
}

.desktop-link {
    display: inline;
}

.social-icons {
    display: flex;
    align-items: center;
    margin-left: 0;
    padding-right: 20px;
    gap: 20px;
}
        
.social-icons a {
    color: var(--primary);
    margin-left: 15px;
    font-size: 1.2rem;
    transition: color 0.3s ease;
}
        
.social-icons a:hover {
    color: var(--secondary); /* Złoty kolor przy najechaniu */
}

/* Material Grid Styles */
.material-grid-container {
    margin: 20px 0;
    text-align: center;
}

.grid-title {
    font-size: 1.5rem;
    margin-bottom: 10px;
    color: var(--dark);
}

.grid-subtitle {
    margin-bottom: 20px;
    color: var(--dark-light);
}

.material-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin-bottom: 20px;
}

.material-item {
    position: relative;
    border: 1px solid var(--light-gray);
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
    display: none; /* Ukrywamy domyślnie - JS będzie pokazywał odpowiednie */
}

.material-item.active {
    border: 3px solid var(--secondary);
    box-shadow: 0 0 0 2px rgba(0,0,0,0.1);
}

.material-item.promotional {
    border: 1px solid var(--light-gray);
}

.material-item.promotional.active {
    border: 3px solid var(--secondary);
    box-shadow: 0 0 0 2px rgba(0,0,0,0.1);
}

.material-item:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.promo-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--secondary);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: bold;
    z-index: 2;
    box-shadow: 0 2px 5px rgba(0,0,0,0.2);
}

.material-item img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.material-info {
    padding: 15px;
    background: white;
}

.material-info h3 {
    margin: 0 0 10px 0;
    font-size: 1rem;
    color: var(--dark);
}

.material-prices {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.material-prices .price {
    font-size: 0.9rem;
    color: var(--dark);
}

.material-prices .old-price {
    text-decoration: line-through;
    color: var(--gray);
    margin-right: 5px;
}

.page-nav {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin: 20px 0;
}

.page-btn {
    padding: 8px 20px;
    background-color: var(--light);
    border: 1px solid var(--secondary);
    color: var(--secondary);
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.page-btn:hover {
    background-color: var(--secondary);
    color: white;
}

.page-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.page-indicator {
    font-size: 0.9rem;
    color: var(--dark);
}

.selected-material {
    text-align: center;
    margin: 15px 0;
    font-weight: bold;
    font-size: 1.2rem;
    color: var(--secondary);
}

.material-samples {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin: 40px 0;
    flex-wrap: wrap;
}

.material-sample {
    flex: 0 0 200px;
    text-align: center;
}

.material-sample img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 5px;
    display: block;
}

/* Responsywność */
@media (max-width: 768px) {
    header {
        background-color: var(--light);
        padding: 10px 0;
        height: 70px;
        box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    }
    
    nav {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        height: 100%;
        padding: 0 15px;
    }
    
    .logo {
        order: 1;
        margin-bottom: 0;
    }
    
    .logo img {
        height: 50px;
    }
    
    .social-icons {
        order: 2;
        position: static;
        display: flex;
        margin-right: 8px;
    }
    
    .hamburger {
        display: block;
        order: 3;
        position: static;
        padding: 10px;
    }
    
    .nav-center {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        width: 100%;
        background-color: var(--light);
        z-index: 1000;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
    }
    
    .nav-center.active {
        display: block;
    }
    
    .nav-links {
        flex-direction: column;
        width: 100%;
        /* USUŃ display: none - to blokowało pokazanie menu */
    }
    
    .nav-links li {
        margin: 0;
        text-align: center;
        padding: 15px 0;
        border-bottom: 1px solid var(--gray);
    }
    
    /* Ukrywamy dropdown na mobile */
    .dropdown-content {
        display: none !important;
    }
    
    /* Ukrywamy strzałkę na mobile */
    .arrow-down {
        display: none;
    }
    
    /* Wyłączamy hover na mobile */
    .dropdown:hover .dropdown-content {
        display: none !important;
    }
    
    .mobile-link {
        display: inline;
    }
    
    .desktop-link {
        display: none;
    }
    
    .contact-container {
        padding: 15px;
    }
    
    .form-section {
        padding: 15px;
    }
    
    .contact-form h1 {
        font-size: 1.8rem;
    }
    
    .contact-form h2 {
        font-size: 1.4rem;
    }

    /* Ukrywanie sidebara na mobile */
    .sidebar {
        display: none;
    }

    /* Dostosowanie głównej zawartości */
    .main-content {
        flex-direction: column;
        padding: 1rem;
    }

    /* Pełna szerokość formularza */
    .page-section {
        width: 100%;
        padding: 0;
        margin: 1rem 0;
    }

    /* Dodatkowe poprawki dla formularza */
    .form-control {
        font-size: 14px;
        padding: 10px;
    }

    .btn-submit {
        padding: 12px;
        font-size: 15px;
    }
    
    .material-grid-container {
        margin: 15px 0;
    }
    
    .grid-title {
        font-size: 1.3rem;
        margin-bottom: 8px;
    }
    
    .grid-subtitle {
        font-size: 0.9rem;
        margin-bottom: 15px;
    }
    
    .material-grid {
        grid-template-columns: repeat(2, 1fr); /* 2 kolumny na mobile */
        gap: 10px;
    }
    
    .material-item img {
        height: 120px;
    }
    
    .material-info {
        padding: 10px;
    }
    
    .material-info h3 {
        font-size: 0.9rem;
        margin-bottom: 5px;
    }
    
    .material-prices {
        gap: 3px;
    }
    
    .material-prices .price {
        font-size: 0.8rem;
    }
    
    .material-prices .old-price {
        font-size: 0.75rem;
    }
    
    .promo-badge {
        font-size: 0.7rem;
        padding: 3px 6px;
        top: 5px;
        right: 5px;
    }
    
    .page-nav {
        gap: 10px;
        margin: 15px 0;
    }
    
    .page-btn {
        padding: 6px 12px;
        font-size: 0.9rem;
    }
    
    .page-indicator {
        font-size: 0.8rem;
    }
    
    .selected-material {
        font-size: 1rem;
    }
    
    .material-sample {
        flex: 0 0 150px;
    }
    
    .material-sample img {
        height: 120px;
    }
}

/* Pozostałe istniejące style */
.product-categories {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
    padding: 2rem 0;
}

.category {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.category:hover {
    transform: translateY(-5px);
}

.category img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.category h3 {
    padding: 1rem 1rem 0;
    color: #333;
}

.category p {
    padding: 0 1rem 1rem;
    color: #666;
}

.btn {
    display: inline-block;
    margin: 0 1rem 1rem;
    padding: 1rem 2rem;
    background-color: var(--primary);
    color: var(--light);
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.btn:hover {
    background-color: var(--secondary);
    color: var(--dark);
}

.stone-gallery {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin: 30px 0;
    justify-content: center;
}
.stone-card {
    width: 280px;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s;
}
.stone-card:hover {
    transform: translateY(-5px);
}
.stone-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}
.stone-info {
    padding: 15px;
}
.stone-name {
    font-weight: 600;
    margin-bottom: 8px;
    color: #333;
}
.service-details {
    list-style: none;
    margin-left: 20px;
    line-height: 1.6;
}
.service-details li {
    margin-bottom: 8px;
    position: relative;
    padding-left: 15px;
}
.service-details li:before {
    content: "•";
    position: absolute;
    left: 0;
    color: #8B6B4A;
}

.logo-section {
    text-align: center;
    margin: 30px 0;
}
.logo-img {
    max-width: 300px;
    height: auto;
    margin: 20px 0;
}
.intro-text {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 40px;
    font-size: 1.1em;
    line-height: 1.6;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  padding-top: 100px;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.9);
}

.modal-content {
  margin: auto;
  display: block;
  width: 80%;
  max-width: 700px;
  animation-name: zoom;
  animation-duration: 0.6s;
}

@keyframes zoom {
  from {transform: scale(0.1)}
  to {transform: scale(1)}
}

.close {
  position: absolute;
  top: 15px;
  right: 35px;
  color: #f1f1f1;
  font-size: 40px;
  font-weight: bold;
  transition: 0.3s;
}

.close:hover,
.close:focus {
  color: #bbb;
  text-decoration: none;
  cursor: pointer;
}

.dropdown {
    position: relative;
}

.arrow-down {
    font-size: 0.7em;
    margin-left: 5px;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--light);
    min-width: 220px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
    z-index: 1000;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 0 0 8px 8px;
    overflow: hidden;
    top: 100%;
    margin-top: 0;
    padding: 0;
    list-style: none;
}

.dropdown-content a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--dark);
    text-decoration: none;
    font-weight: 500;
    transition: all 0.3s ease;
    background-color: var(--light);
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.dropdown-content a:hover {
    background-color: var(--secondary);
    color: white;
}

.dropdown:hover .dropdown-content {
    display: block;
    animation: fadeIn 0.3s ease-in-out;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateX(-50%) translateY(-10px); }
    to { opacity: 1; transform: translateX(-50%) translateY(0); }
}

.main-content {
    display: flex;
    gap: 2rem;
    padding: 2rem;
    align-items: flex-start;
}

.sidebar {
    width: 300px;
    background-color: #f5f5f5;
    padding: 1.5rem;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.05);
}

.sidebar h2 {
    font-size: 1.3rem;
    margin-bottom: 1.2rem;
    color: #333;
    border-bottom: 1px solid #ddd;
    padding-bottom: 0.5rem;
}

.sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar-menu li {
    margin-bottom: 0.6rem;
}

.sidebar-menu a {
    display: block;
    text-decoration: none;
    color: #333;
    font-weight: 600;
    padding: 0.6rem 0.8rem;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.sidebar-menu a:hover {
    background-color: #e9e9e9;
    text-decoration: none;
}

/* Styl dla aktywnego linku */
.sidebar-menu a.active {
    background-color: var(--secondary);
    color: var(--dark);
    font-weight: 700;
    position: relative;
}

/* Dodatkowy element wizualny dla aktywnego linku */
.sidebar-menu a.active::before {
    content: "";
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 4px;
    background-color: #a38556;
    border-radius: 4px 0 0 4px;
}

.page-section {
    flex-grow: 1;
}

.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 2rem;
}

.product {
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 1rem;
    background-color: #fff;
    text-align: center;
}

.product img {
    max-width: 100%;
    height: auto;
    border-radius: 6px;
    margin-bottom: 1rem;
}

.fireplace-quote-info {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 30px 0;
    border-left: 4px solid var(--secondary);
}

.fireplace-quote-info h3 {
    margin-top: 0;
    color: var(--secondary);
}

.fireplace-quote-info a {
    color: var(--secondary);
    font-weight: 600;
}

footer {
    background-color: var(--light);
    color: black;
    text-align: center;
    padding: 1.5rem 0;
    font-size: 0.9rem;
    margin-top: auto;
}

.footer-contact a {
    color: var(--secondary);
    text-decoration: none;
}
