/* General Body Styling */
* {
    box-sizing: border-box;
}

body {
    font-family: 'Georgia', serif;
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background: #f4f2ed;
    color: #333;
}

/* Header Styling */
header {
    background: #506f3b;
    color: #fff;
    padding: 3rem 0; /* Increased padding */
    text-align: center;
    background-image: url('../images/content/enten_im_schnee.jpg'); /* Winter image */
    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.7); /* Added for better text readability */
}

header h1 {
    margin: 0;
    font-family: 'Helvetica', sans-serif;
    font-size: 2.5rem;
}

.logo {
    height: auto;
    width: 100%;
    max-width: 500px;
    margin: 1rem auto;
    display: block;
}

/* Navigation Styling */
nav {
    background: #333;
    color: #fff;
    padding: 0.5rem 0;
    text-align: center;
    position: relative; /* For positioning the toggle */
}

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

.nav-menu li {
    display: inline;
    margin: 0 15px;
}

nav a {
    color: #fff;
    text-decoration: none;
    font-size: 1.2rem;
}

nav a:hover {
    text-decoration: underline;
}

/* Mobile Navigation Toggle */
.nav-toggle {
    display: none; /* Hidden by default */
    background: none;
    border: none;
    color: #fff;
    font-size: 2rem;
    cursor: pointer;
    position: absolute;
    top: 5px;
    right: 20px;
}

/* Media Query for Mobile Devices */
@media (max-width: 768px) {
    nav {
        text-align: left;
        min-height: 50px; /* Ensure height for the button */
    }

    .nav-toggle {
        display: block; /* Show toggle on mobile */
        z-index: 1000; /* Ensure it's on top */
        position: absolute;
        top: 50%;
        right: 20px;
        transform: translateY(-50%);
        line-height: 1;
        padding: 5px;
    }

    .nav-menu {
        display: none; /* Hide menu by default on mobile */
        flex-direction: column;
        width: 100%;
        background-color: #333;
    }

    .nav-menu.show {
        display: flex; /* Show menu when toggled */
    }

    .nav-menu li {
        display: block;
        margin: 0;
        text-align: center;
        border-top: 1px solid #444;
    }

    .nav-menu li a {
        display: block;
        padding: 15px;
    }
}

/* Main Content Styling */
main {
    padding: 20px;
    max-width: 1100px;
    margin: 0 auto;
}

/* Footer Styling */
footer {
    text-align: center;
    padding: 20px;
    background: #333;
    color: #fff;
}

/* Section Styling */
.section {
    margin-bottom: 2rem;
}

.section h2 {
    border-bottom: 2px solid #506f3b;
    padding-bottom: 10px;
    margin-bottom: 1rem;
}

/* Form Styling */
form {
    background: #fff;
    padding: 2rem;
    border: 1px solid #ddd;
}

form label {
    display: block;
    margin-bottom: 0.5rem;
}

form input,
form textarea {
    width: 100%;
    padding: 0.5rem;
    margin-bottom: 1rem;
    border: 1px solid #ddd;
}

form button {
    background: #506f3b;
    color: #fff;
    padding: 0.7rem 1.5rem;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

form button:hover {
    background: #3e562d;
}

/* Gallery Styling */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.gallery img {
    width: 100%;
    height: auto;
    border: 3px solid #ddd;
    border-radius: 5px;
}

/* Product List Styling */
.product-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 20px;
    margin-bottom: 2rem;
}

.product-item {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
    padding: 1rem;
    display: flex;
    flex-direction: column;
}

.product-item img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-bottom: 1px solid #ddd;
    margin-bottom: 1rem;
}

.product-details h3 {
    margin-top: 0;
}

.product-details .price {
    font-weight: bold;
    color: #506f3b;
}

.status-available {
    color: #28a745;
    font-weight: bold;
}

.status-unavailable {
    color: #dc3545;
    font-weight: bold;
}

.product-order-controls {
    margin-top: auto;
    padding-top: 1rem;
}

.product-order-controls input {
    width: 60px;
    margin-right: 10px;
}

.product-order-controls button, .button {
    background: #506f3b;
    color: #fff;
    padding: 0.5rem 1rem;
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

form button:hover, .button:hover {
    background: #3e562d;
}

/* Order Form Styling */
.order-form {
    margin-top: 2rem;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
}

form input,
form textarea {
    width: 100%;
    padding: 0.5rem;
    margin-bottom: 1rem;
    border: 1px solid #ddd;
    box-sizing: border-box; /* Ensures padding doesn't add to width */
}

textarea#order-summary {
    background: #e9ecef;
    font-family: monospace;
}

.order-confirmation {
    background: #e6f9e6;
    border: 1px solid #506f3b;
    padding: 1rem;
    margin-bottom: 2rem;
}

.error {
    color: #dc3545;
    font-weight: bold;
    border: 1px solid #dc3545;
    padding: 1rem;
    background: #f8d7da;
    margin-bottom: 1rem;
}


.important-notice {
    background: #fff3cd;
    border: 1px solid #ffeeba;
    color: #856404;
    padding: 1rem;
    margin-bottom: 1.5rem;
    border-radius: 5px;
}

/* Shopping Cart Styling */
.cart-container {
    background: #f9f9f9; /* Subtle background */
    border: 1px solid #eee; /* Light border */
    padding: 1.5rem; /* Restore some padding */
    margin-bottom: 1rem; /* Slightly less margin */
    border-radius: 5px;
}
.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    border-bottom: 1px solid #eee;
}
.cart-item:last-child {
    border-bottom: none;
}
.cart-item-details {
    flex-grow: 1;
}
.cart-item-actions input {
    width: 50px;
    text-align: center;
    margin-right: 10px;
}
.cart-item-actions button {
    background: #dc3545;
    color: white;
    border: none;
    padding: 0.3rem 0.6rem;
    cursor: pointer;
    border-radius: 3px;
}
#cart-total {
    text-align: right;
    margin-top: 1rem;
    font-size: 1.2rem;
}

/* Footer Logos */
.footer-logos {
    margin-bottom: 1rem;
}
.footer-logo {
    height: 50px;
    margin: 0 10px;
}

nav a.active {
    color: #ffd700; /* Gold color for the active link */
}

/* Card Layout */
.card-container {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    justify-content: center;
}

.card {
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 5px 20px;
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 800px; /* Adjust as needed */
}

.card-content {
    flex-grow: 1;
}

.card-icon {
    width: 50px; /* Adjust size as needed */
    height: 50px;
    margin-right: 15px;
    margin-left: 0;
}

/* About Us Section Layout */
.about-us-container {
    display: block;
    overflow: hidden; /* Clearfix */
}

.about-us-container img {
    float: left;
    margin-right: 2rem;
    margin-bottom: 1rem;
    width: 300px;
    max-width: 40%;
    height: auto;
}



/* Philosophy Section Layout */
.philosophy-container {
    display: flex;
    flex-wrap: wrap; /* Allow wrapping on smaller screens */
    gap: 20px;
    align-items: flex-start;
}

.philosophy-image-card {
    flex: 1 1 300px; /* Flex-grow, flex-shrink, flex-basis */
}

.philosophy-image-card img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.philosophy-text-cards {
    flex: 2 1 500px; /* Takes up more space */
    display: flex;
    flex-direction: column;
    gap: 10px;
}


/* Rounded Image Style */
.rounded-image {
    border-radius: 8px;
}

.philosophy-intro-text {
    max-width: 800px;
    margin: 0 auto 20px auto;
}

section.galerie {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
    grid-auto-rows: 200px;
    gap: 1em;
    grid-auto-flow: dense;
    margin: 0 calc(700px - 45vw);
    background: none;
    padding: 20px;
}

section.galerie figure {
    box-shadow: 0px 0px 5px rgba(51, 51, 51, 0.2);
    border-radius: 5px;
    position: relative;	
    margin: 0;   /* figure hat sonst einen browsereigenen Abstand! */	
}

section.galerie figure.h1 { grid-row: span 1; }
section.galerie figure.h2 { grid-row: span 2; }
section.galerie figure.h3 { grid-row: span 3; }

section.galerie figure.w1 { grid-column: span 1; }
section.galerie figure.w2 { grid-column: span 2; }
section.galerie figure.w3 { grid-column: span 3; }
section.galerie figure.w4 { grid-column: span 4; }
section.galerie figure.w5 { grid-column: span 5; }
section.galerie figure.w6 { grid-column: span 6; }
section.galerie figure.w7 { grid-column: span 7; }
@media only screen and (max-width: 980px) {section.galerie figure.w7 , section.galerie figure.w6 , section.galerie figure.w5 { grid-column: span 5; } section.galerie {margin:0 5px;}}
@media only screen and (max-width: 710px) {
    section.galerie figure.w1 { grid-column: span 2; }
    section.galerie figure.w2 { grid-column: span 2; }
    section.galerie figure.w3 { grid-column: span 4; }
    section.galerie figure.w4 { grid-column: span 4; }
    section.galerie figure.w5 { grid-column: span 4; }
    section.galerie figure.w6 { grid-column: span 4; }
    section.galerie figure.w7 { grid-column: span 4; }
}
@media only screen and (max-width: 550px) {
    section.galerie figure.w1 { grid-column: span 4; }
    section.galerie figure.w2 { grid-column: span 4; }
    section.galerie figure.w3 { grid-column: span 4; }
    section.galerie figure.w4 { grid-column: span 4; }
    section.galerie figure.w5 { grid-column: span 4; }
    section.galerie figure.w6 { grid-column: span 4; }
    section.galerie figure.w7 { grid-column: span 4; }
}

section.galerie figure.text { 
    background-color:#eee;
	position: relative;
}

section.galerie figure.text div {
	padding: 10px 20px !important;
	border-radius:5px;
	height: calc(100% - 20px);
	width: calc(100% - 40px);
}

section.galerie figure.text h1 {
    margin: 10px 5px;
    text-shadow: none;
}

section.galerie figure.text p {
    margin: 10px 0 0 10px;
    text-align: left;
}
 
section.galerie figure img {
    border-radius: 5px;
    display: block;
    object-fit: cover;
    width: 100%;
    height: 100%;
}
/* Add to Cart Feedback Styling */
.product-order-controls {
    position: relative; /* Needed for positioning the feedback message */
}
.add-to-cart-feedback {
    position: absolute;
    bottom: 100%; /* Position above the button */
    left: 50%;
    transform: translateX(-50%);
    background-color: #28a745; /* Green background */
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.9em;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
    white-space: nowrap;
}
.add-to-cart-feedback.show {
    opacity: 1;
    visibility: visible;
}


/* Cart Table Styling */
.cart-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0;
}
.cart-table th, .cart-table td {
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 8px 4px;
    text-align: left;
}
.cart-table th {
    background-color: transparent;
    font-weight: bold;
    border: none;
}
.cart-table .cart-quantity-input {
    width: 60px;
    padding: 5px;
}
.cart-table .cart-remove-btn {
    background: #dc3545;
    color: white;
    border: none;
    padding: 8px 12px;
    cursor: pointer;
    border-radius: 4px;
}
.cart-table .cart-remove-btn:hover {
    background: #c82333;
}
#cart-total {
    text-align: right;
    margin-top: 20px;
    font-size: 1.2em;
}


.cart-table th:nth-child(2), .cart-table td:nth-child(2) { width: 10%; } /* Menge */
.cart-table th:nth-child(3), .cart-table td:nth-child(3) { width: 15%; } /* Preis */
.cart-table th:nth-child(4), .cart-table td:nth-child(4) { width: 10%; text-align: center;} /* Aktion */


/* Admin Page Styling */
.admin-section {
    background-color: #fff;
    padding: 2rem;
    border: 1px solid #ddd;
    border-radius: 5px;
}
.login-form {
    max-width: 400px;
    margin: 2rem auto;
}
.admin-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 2rem;
}
.admin-table th, .admin-table td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: left;
}
.admin-table th {
    background-color: #f2f2f2;
}
.delete-btn {
    color: #dc3545;
    text-decoration: none;
    font-weight: bold;
}
.delete-btn:hover {
    text-decoration: underline;
}


.doc-link::before {
    content: '';
    display: inline-block;
    width: 20px;
    height: 20px;
    margin-right: 8px;
    background-image: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGNsYXNzPSJpY29uIGljb24tdGFibGVyIGljb24tdGFibGVyLWZpbGUtdGV4dCIgd2lkdGg9IjI0IiBoZWlnaHQ9IjI0IiB2aWV3Qm94PSIwIDAgMjQgMjQiIHN0cm9rZS13aWR0aD0iMiIgc3Ryb2tlPSJjdXJyZW50Q29sb3IiIGZpbGw9Im5vbmUiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCI+PHBhdGggc3Ryb2tlPSJub25lIiBkPSJNMCAwaDI0djI0SDB6IiBmaWxsPSJub25lIi8+PHBhdGggZD0iTTE0IDN2NEg1YTQgNCAwIDAgMCAwIDhoMTRhMiAyIDAgMCAwIDAtNGgtNXYtNGwiIC8+PHBhdGggZD0iTTUgMTF2LTZoMTFsMyAzIDMgMy0xMSAxMXotMTF6IiAvPjxsaW5lIHgxPSI5IiB5MT0iMTQiIHgyPSIxNSIgeTI9IjE0IiAvPjxsaW5lIHgxPSI5IiB5MT0iMTciIHgyPSIxNSIgeTI9IjE3IiAvPjwvc3ZnPg==');
    background-size: contain;
    background-repeat: no-repeat;
    vertical-align: middle;
}

