/*
Theme Name: Margaret
Theme URI: https://madebymade.pl
Author: Made
Author URI: https://madebymade.pl
Version: 1.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: margaret
*/

@import "css/fonts.css";

body,
html {
    overflow-x: hidden;
    width: 100vw;
}


body {
    font-family: "neue-haas-grotesk-display", sans-serif;
    font-weight: 400;
    font-style: normal;
    font-size: 17px;
    line-height: 1.25;
    margin: 0;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;  
}

.footer-logo {
    position: relative;
    height: 14vw;
    overflow: hidden;

    span {
        position: absolute;
        left: 50%;
        z-index: 100;
        top: 0;
        transform: translateX(-50%);
        font-family: 'PPCirka';
        font-weight: 300;
        font-size: 25vw;
        line-height: 25vw;
    }
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'PPCirka';
    font-weight: 300;
}

h1 {
    font-size: 112px;
    line-height: 0.875;
    margin: 0 0 40px 0;
}

h2 {
    font-size: 60px;
    line-height: 0.875;
    margin: 10px 0 20px 0;
}

.site {
    position: relative;
}

.main-navigation {
    position: fixed;
    left: 20px;
    top: 20px;
    z-index: 100;

    .logo {
        display: block;
        margin-bottom: 20px;
        width: 180px;

        img {
            width: 100%;
            height: auto;
            display: block;
            object-fit: contain;
        }
    }

    ul {
        list-style: none;
        margin: 0;
        padding: 0;
        display: block;
    }

    li {
        display: block;

        a {
            position: relative;
            text-decoration: none;
            color: inherit;
            display: inline-block;
            text-transform: uppercase;
        }

        a::after {
            content: "";
            position: absolute;
            left: 0;
            bottom: 0;
            width: 100%;
            height: 1px;
            background: currentColor;
            transform: scaleX(0);
            transform-origin: right;
            transition: transform .35s ease;
        }

        &.current-menu-item a::after,
        a:hover::after {
            transform: scaleX(1);
            transform-origin: left;
        }
    }

}



.admin-bar .main-navigation {
    top: 52px;
}

/* Basic styling for the layout */

.content-blocks-container {
    padding: 20px;
    border-bottom: 1px solid #ccc;
    position: relative;
    width: 100%;
    overflow: hidden;
    box-sizing: border-box;
}

.page-template-order-template .site {
    border-bottom: 1px solid #ccc;
    position: relative;
}

.page-template-order-template .left-column {
    padding-top: 280px;
}

.content-blocks-container a {
    position: relative;
    text-decoration: none;
    color: inherit;
    display: inline-block;
}

.content-blocks-container a::after {
    content: "";
    position: absolute;
    left: 0;
    bottom: 0;
    width: 100%;
    height: 1px;
    background: currentColor;
    transform: scaleX(1);
    transform-origin: right;
    transition: transform .35s ease;
}

.content-blocks-container a:hover::after {
    transform: scaleX(0);
    transform-origin: left;
}


.content-blocks-container::after,
.page-template-order-template .site::after {
    content: "";
    display: block;
    width: 1px;
    height: 100%;
    position: absolute;
    top: 0;
    left: 50%;
    background-color: #ccc;
    transform: translateX(-50%);
}


.home .site-main {
    position: relative;
    padding-top: 100px;
}

.home .content-blocks-container::after {
    display: none;
}

.content-row {
    margin-bottom: 40px;
}

.content-row p {
    margin: 0 0 15px 0;
}

.row-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 49px;
}

.row-wrapper.full-width {
    grid-template-columns: 1fr;
    position: relative;
    z-index: 2;
}

.full-width-column,
.left-column,
.right-column {
    display: flex;
    flex-direction: column;
    gap: 20px;
    position: relative;
    z-index: 5;
}

.photo-block {
    margin-bottom: 40px;
}

.photo-block img {
    max-width: 100%;
    height: auto;
    display: block;
}

.photo-block.full-width img {
    width: 100%;
}

.photo-block.align-left img {
    margin-right: auto;
}

.photo-block.align-center img {
    margin-left: auto;
    margin-right: auto;
}

.photo-block.align-right img {
    margin-left: auto;
}

.photo-block.align-left,
.photo-block.align-center,
.photo-block.align-right {
    img {
        max-width: 66%;
    }
}

.gallery-block {
    display: flex;
    gap: 20px;
    margin: 20px 0 60px 0;
    position: relative;
    z-index: 2;
}

.full-width-column {
    position: relative;
    z-index: 2;
}

.full-width-column .photo-block {
    position: relative;
    z-index: 3;
}

.home .site-main::after,
.full-width-column .photo-block::after,
.full-width-column .gallery-block::after {
    content: "";
    position: absolute;    
    left: 50%;
    width: 200vw;
    transform: translate(-100vw, 0);
    height: 50%;
    z-index: -1;
}

.full-width-column .photo-block::after {
    bottom: 0;
    background-color: #dadada;
}

.home .site-main::after {
    bottom: 0;
    background-color: #dadada;
}

.full-width-column .photo-block::after,
.full-width-column .gallery-block::after {
    height: 80%;
    background-color: #f3dacc;
}


.full-width-column .photo-block::after {
    top: 50%;
}


.full-width-column .gallery-block::after {
    bottom: 50%;
}

.video-block {
    margin-bottom: 40px;
}

.video-wrapper {
    width: 100%;
    max-width: 100%;

}

.video-wrapper video {
    width: 100%;
    height: auto;
    object-fit: contain;
    display: block;
}

.hr-block {
    position: relative;
    margin: 20px 0;

    hr {
        display: block;
        border: none;
        position: absolute;
        top: 0;
        height: 1px;
        left: -25px;
        background-color: #ccc;
        width: 50vw;
    }
}


.content-block {
    font-size: 1rem;
    line-height: 1.25;
}

.fixed-block {
    padding-left: 50px;
    position: fixed;
    width: 200px;
    left: 20px;
    bottom: 20px;
    transition: 300ms all ease;

    p {
        margin: 0;
    }
}

.scrolled .fixed-block {
    opacity: 0;
}


.fixed-block::before {
    border-radius: 50%;
    content: "";
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 40px;
    height: 40px;
    background-color: #000;
}


.two-cols-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.two-cols-wrapper>*,
.row-wrapper>* {
    min-width: 0;
}

.footer {
    height: 100px;
    gap: 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin: auto 20px 0 20px;
    text-transform: uppercase;

    a {
        text-decoration: none;
        color: #000;
        display: block;
        text-transform: uppercase;
    }
}

.footer-cto,
.footer-contact {
    width: 100%;
}

.footer-cto {
    text-align: center;
}

.footer-contact {
    text-align: right;
}

.footer-logo-image {
    text-align: right;
    margin: 20px 0;

    img {
        max-width: 50%;
        height: auto;
        display: inline-block;
    }
}

.footer-navigation {
    width: 100%;

    ul {
        list-style: none;
        margin: 0;
        padding: 0;
        display: flex;
        align-items: center;
    }

    li {
        display: flex;
        align-items: center;
        padding: 0;
        margin: 0;
    }

    li::before {
        display: inline-block;
        content: ", ";
        color: #000;
        margin-right: 10px;
    }

    li:first-child::before {
        content: "";
        margin: 0;
    }
}

.embla {
  overflow: hidden;
  width: 100%;
}

.embla__viewport {
  overflow: hidden;
}

.embla__container {
  display: flex;
  gap: 60px;
}

.embla__slide {
    display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
}

.embla__slide:last-child {
  margin-right: 60px;
}

.embla__slide img {
  width: 380px;
  height: auto;
  display: block;
}

.offset2 img { transform: translateY(20%); }
.offset4 img { transform: translateY(-10%); }


/* Modal Overlay */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* Modal Container */
.modal-container {
    display: flex;
    max-width: 900px;
    width: 90%;
    background: white;
    overflow: hidden;
}

.modal-container.modal-small {
    max-width: 500px;
}

/* Left Side - Image */
.modal-image {
    flex: 1;
    background-position: center center;
    background-size: cover;
    min-height: 500px;
}

/* Right Side - Content */
.modal-content {
    flex: 1;
    padding: 60px 50px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.modal-logo {
    margin: 0 auto 10px auto;
    width: 180px;
}

.modal-title {
    font-size: 48px;
    font-weight: 400;
    font-family: "neue-haas-grotesk-display", sans-serif;
    margin-bottom: 40px;
    color: #000;
}

.modal-small .modal-title {
    font-size: 32px;
    margin-bottom: 20px;
}

.modal-message {
    font-size: 16px;
    margin-bottom: 30px;
    color: #333;
}

.modal-question {
    font-size: 16px;
    margin-bottom: 30px;
    color: #333;
}

.modal-buttons {
    display: flex;
    gap: 20px;
}

.modal-button {
    padding: 15px 40px;
    font-size: 17px;
    font-weight: 400;
    text-transform: uppercase;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
}

.modal-button.yes {
    background-color: #000;
    color: #fff;
}

.modal-button.yes:hover {
    background-color: #333;
}

.modal-button.no {
    background-color: #000;
    color: #fff;
}

.modal-button.no:hover {
    background-color: #333;
}

/* ========================================
   FORM STYLES
   ======================================== */

.order-title {
    font-size: 60px;
    margin: 0 0 30px 0;
}

.order-form {
    margin: 40px auto;
    width: 90%;
}

.wine-item {
    display: grid;
    grid-template-columns: 260px 1fr;
    gap: 30px;
    margin-bottom: 80px;
    align-items: start;
}

.wine-image img {
    max-width: 200px;
    height: auto;
    display: block;
    margin: 0 auto;
}

.wine-info h2 {
    font-size: 60px;
    margin-bottom: 20px;
}

.wine-info p {
    margin: 8px 0;
}

.wine-order {
    margin-top: 20px;
}

.select-wrapper {
    margin-top: 10px;
}


.wine-info select {
    padding: 10px 24px 10px 12px;
    border: 1px solid #333;
    font-size: 16px;
    appearance: none;
    border-radius: 0;
    background-image: url(img/dropdown.svg);
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 12px auto;
}

.out {
    color: #777;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-top: 30px;
}

.form-grid input {
    box-sizing: border-box;
    width: 100%;
    padding: 14px;
    border: 1px solid #333;
}

.customer-title {
    margin: 30px 0;
}

.form-full {
    grid-column: 1/-1;
}

button.submit-order {
    margin-top: 40px;
    padding: 16px 40px;
    background: black;
    color: white;
    border: none;
    font-size: 16px;
    cursor: pointer;
}

.form-field {
    display: flex;
    flex-direction: column;
}

.form-field label {
    font-size: 16px;
    display: block;
    margin-bottom: 5px;
}

.form-field input,
.wine-qty {
    padding: 14px;
    border: 1px solid #444;
    font-size: 16px;
    transition: all .2s;
}

.form-field input.error {
    border: 2px solid #d63638;
    background: #fff7f7;
}

.wine-qty.error {
    border: 2px solid #d63638;
}

.error-msg {
    font-size: 13px;
    color: #d63638;
    margin-top: 6px;
    min-height: 16px;
    display: none;
}

.error-msg.has-error {
    display: block;
}

.form-error-global {
    background: #fff3f3;
    border: 1px solid #d63638;
    padding: 15px;
    margin-bottom: 20px;
}

.form-success {
    background: #f0f7f0;
    border: 1px solid #2ea043;
    padding: 15px;
    margin-bottom: 20px;
}

/* ========================================
   RESPONSIVE STYLES - TABLET & MOBILE
   ======================================== */

/* Tablet - 1024px and below */
@media (max-width: 1024px) {


    h1 {
        font-size: 74px;
    }

    h2 {
        font-size: 45px;
    }

    .row-wrapper {
        gap: 30px;
    }

    .fixed-block {
        width: 150px;
        padding-left: 45px;
    }

    .fixed-block::before {
        width: 35px;
        height: 35px;
    }
}

/* Tablet - 768px and below */
@media (max-width: 768px) {

    .home .site-main::after {
        height: 75%;
    }

    .full-width-column .photo-block::after,
    .full-width-column .gallery-block::after {
        height: 110%;
    }


    .footer-logo-image {

        img {
            max-width: 100%;
        }
    }


    h1 {
        font-size: 56px;
    }

    h2 {
        font-size: 30px;
    }

    .site {
        padding-top: 240px;
    }

    .home .site {
        padding-top: 160px;
    }

    .embla__slide img  {
        width: 240px;
    }


    .offset2 img { transform: translateY(40%); }
    .offset4 img { transform: translateY(-20%); }


    .page-template-order-template .left-column {
        padding-top: 0;
    }    

    /* Modal responsive */
    .modal-container {
        flex-direction: column;
        max-width: 500px;
    }

    .modal-image {
        min-height: 250px;
    }

    .modal-content {
        padding: 40px 30px;
    }

    .modal-buttons {
        flex-direction: column;
        width: 100%;
    }

    .modal-button {
        width: 100%;
    }

    /* Main navigation adjustments */
    .main-navigation {
        left: 15px;
        top: 15px !important;
        position: absolute;
    }

    .main-navigation .logo {
        width: 140px;
        margin-bottom: 15px;
    }

    /* Content blocks container - hide center divider on mobile */
    .content-blocks-container {
        padding: 15px;
    }

    .content-blocks-container::after,
    .page-template-order-template .site::after {
        display: none;
    }

    /* Two column layouts become single column */
    .row-wrapper,
    .two-cols-wrapper {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .wine-item {
        grid-template-columns: 1fr;
        gap: 30px;
        margin-bottom: 60px;        
    }

    .wine-image {
        
    }

    .wine-image img {
        max-width: 140px;
        margin: 0;
    }

    .wine-info h2 {
        font-size: 32px;
        margin-bottom: 15px;
    }

    .form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    /* Photo blocks - increase max-width on mobile */
    .photo-block.align-left,
    .photo-block.align-center,
    .photo-block.align-right {
        img {
            max-width: 100%;
        }
    }

    /* HR block adjustments */
    .hr-block hr {
        left: -15px;
        width: calc(100vw - 30px);
    }

    /* Fixed block adjustments */
    .fixed-block {
        position: static;
        width: 100%;
        padding-left: 0;
        padding: 15px;
        text-align: center;
    }

    .fixed-block::before {
        display: none;
    }

    /* Footer adjustments */
    .footer {
        flex-direction: column;
        height: auto;
        padding: 20px 0;
        gap: 15px;
        margin: auto 15px 0 15px;
    }

    .footer-cto,
    .footer-contact {
        text-align: left;
    }

    .footer-navigation ul {
        flex-direction: column;
        gap: 10px;
        align-items: start
    }

    .footer-navigation li::before {
        display: none;
    }
}

/* Mobile - 480px and below */
@media (max-width: 480px) {

    .main-navigation {
        left: 10px;
        top: 10px;
    }

    .main-navigation .logo {
        width: 120px;
    }

    .content-blocks-container {
        padding: 10px;
    }

    .content-row {
        margin-bottom: 30px;
    }

    .photo-block,
    .video-block {
        margin-bottom: 30px;
    }

    .modal-logo {
        width: 140px;
    }
}