/* summary.css - Complete File */
.back-button-container{
    display: block;
    margin-top: 40px;
    margin-bottom: 48px;
    margin-left: 80px;
    margin-right: 80px;
    width: fit-content;
}

.back-button{
    background: #FBFAF9;
    border: #F0EFEB solid 1px;
    border-radius: 300px;
    padding: 10px;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.back-button:hover {
    background: #F5F4F2;
}

.back-button img {
    width: 20px;
    height: 20px;
}

a{
    text-decoration: none;
}

.page-header{
    margin-left: 80px;
    margin-right: 80px;
    margin-bottom: 80px;
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.order-section{
    margin-left: 80px;
    margin-right: 80px;
    margin-bottom: 80px;
    display: flex;
    justify-content: space-between;
    gap: 96px;
}

.order-details{
    display: flex;
    flex-direction: column;
    gap: 48px;
    width: 50%;
    height: fit-content;
}

.page-title h1{
    font-family: 'Geist', sans-serif;
    font-size: 48px;
    font-weight: 400;
    color: #222221;
    margin: 0;
    text-align: flex-start;
    letter-spacing: -0.4px;
}

.card {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 24px;
    padding: 24px 20px;
    background: rgb(237, 236, 231, 0.5);
    border-radius: 12px;
    border: #EDECE7 solid 1px;
    transition: all 0.3s ease;
}

.card-1{
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.card:hover {
    transform: translateY(-3px);
}

#card {
    background: rgb(246, 242, 220, 0.5);
    border-radius: 12px;
    border: #F6F2DC solid 1px;
}

.card-title{
    display: flex;
    justify-content: space-between;
}

.card h2 {
    font-family: 'Geist', sans-serif;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.4px;
    line-height: auto;
    color: #222221;
    margin: 0;
}

.card p {
    font-family: 'Geist', sans-serif;
    font-size: 18px;
    font-weight: 400;
    color: #72706F;
    line-height: auto;
    letter-spacing: -0.4px;
    margin: 0;
}

.title-sub{
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.title-sub h2{
    font-family: 'Geist', sans-serif;
    font-size: 20px;
    font-weight: 500;
    color: #222221;
    margin: 0;
    text-align: flex-start;
    letter-spacing: -0.4px;
}

.title-sub p{
    font-family: 'Geist', sans-serif;
    font-size: 18px;
    font-weight: 400;
    color: #898683;
    line-height: auto;
    letter-spacing: -0.4px;
    margin: 0;
}

.special-request {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.special-request h2{
    font-family: 'Geist', sans-serif;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.4px;
    line-height: auto;
    color: #222221;
    margin: 0;
}

.special-request textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #E0E0E0;
    border-radius: 12px;
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    line-height: 1.5;
    color: #222221;
    background: #FFFFFF;
    resize: vertical;
    outline: none;
    transition: all 0.3s ease;
    min-height: 120px;
    box-sizing: border-box;
}

.special-request textarea::placeholder {
    color: #A0A0A0;
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    opacity: 1;
}

.special-request textarea:focus {
    border-color: #A7A7A7;
    box-shadow: 0 0 0 2px rgba(114, 112, 111, 0.1);
}

.special-request textarea.warning {
    border-color: #F0AD4E;
    box-shadow: 0 0 0 2px rgba(240, 173, 78, 0.1);
}

.special-request textarea.limit {
    border-color: #D9534F;
    box-shadow: 0 0 0 2px rgba(217, 83, 79, 0.1);
}

.counter {
    margin-top: 8px;
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    color: #72706F;
    text-align: right;
}

.counter.warning {
    color: #F0AD4E;
}

.counter.limit {
    color: #D9534F;
    font-weight: 500;
}

/* Right Side: Contact & Payment Cards */
.order-summary {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 48px;
    width: 50%;
}

/* Order Summary Card (Moved from left to right) */
.order-summary-card {
    display: flex;
    flex-direction: column;
    gap: 32px;
    padding: 32px;
    background: rgb(237, 236, 231, 0.5);
    border-radius: 12px;
    border: #EDECE7 solid 1px;
    transition: all 0.3s ease;
}

.order-summary-card:hover {
    transform: translateY(-3px);
}

.summary-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.summary-title {
    font-family: 'Geist', sans-serif;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.4px;
    color: #222221;
    margin: 0;
}

.section-subtitle {
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #72706F;
    line-height: 1.4;
    letter-spacing: -0.2px;
    margin: 0;
}

/* Order Items */
.order-items {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.order-item {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding-bottom: 12px;
    border-bottom: 1px solid #EDECE7;
}

.order-item:last-child {
    border-bottom: none;
}

.item-description {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.item-name {
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    font-weight: 400;
    color: #222221;
    line-height: 1.4;
}

.item-price {
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #222221;
    white-space: nowrap;
}

.order-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 12px;
    border-top: 1px solid #222221;
    margin-top: 4px;
}

.total-label {
    font-family: 'Geist', sans-serif;
    font-size: 18px;
    font-weight: 500;
    color: #222221;
}

.total-amount {
    font-family: 'Geist', sans-serif;
    font-size: 20px;
    font-weight: 500;
    color: #222221;
}

.prep-time {
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #72706F;
    line-height: 1.4;
    margin: 0;
    font-style: italic;
}

/* Contact Card with updated spacing */
.contact-card {
    display: flex;
    flex-direction: column;
    gap: 32px;
    padding: 32px;
    background: rgb(237, 236, 231, 0.5);
    border-radius: 12px;
    border: #EDECE7 solid 1px;
    transition: all 0.3s ease;
}

.contact-card:hover {
    transform: translateY(-3px);
}

.contact-section {
    display: flex;
    flex-direction: column;
    gap: 24px; /* 24px gap from title-sub to fields */
}

.contact-section .title-sub {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.contact-fields {
    display: flex;
    flex-direction: column;
    gap: 20px; /* 20px gap between input fields */
}

.contact-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* Field error should not create gap when empty */
.field-error {
    color: #FF6B6B;
    font-size: 12px;
    font-family: 'Geist', sans-serif;
    min-height: 0; /* Remove fixed min-height */
    height: 0; /* Start with zero height */
    overflow: hidden;
    opacity: 0;
    transition: height 0.2s ease, opacity 0.2s ease;
}

.field-error:not(:empty) {
    height: 16px; /* Expand when there's content */
    opacity: 1;
    margin-top: 4px; /* Only add margin when visible */
}

.contact-field label {
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #222221;
    letter-spacing: -0.2px;
}

.contact-field input {
    padding: 12px 16px;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    color: #222221;
    background: #FFFFFF;
    transition: all 0.3s ease;
    outline: none;
}

.contact-field input:focus {
    border-color: #72706F;
    box-shadow: 0 0 0 2px rgba(114, 112, 111, 0.1);
}

.contact-field input.error {
    border-color: #FF6B6B;
}

.contact-field input.valid {
    border-color: #51CF66;
}

/* Payment Card */
.payment-card {
    display: flex;
    flex-direction: column;
    gap: 32px;
    padding: 32px;
    background: rgb(237, 236, 231, 0.5);
    border-radius: 12px;
    border: #EDECE7 solid 1px;
    transition: all 0.3s ease;
}

.payment-card:hover {
    transform: translateY(-3px);
}

.payment-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.payment-details {
    display: flex;
    flex-direction: column;
    gap: 16px;
    background: #F9F9F8;
    border-radius: 8px;
    padding: 20px;
}

.payment-row {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: start;
    gap: 6px;
}

.payment-label {
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #72706F;
}

.payment-value {
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #222221;
}

.hatee-signature {
    display: flex;
    justify-content: center;
    margin-top: 16px;
}

.hatee-signature .signature {
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #72706F;
    letter-spacing: 0.5px;
    font-style: italic;
}

/* Confirm Payment Button */
.confirm-payment-btn {
    width: 100%;
    padding: 18px 32px;
    background: #222221;
    color: #FFFFFF;
    border: none;
    border-radius: 300px;
    font-family: 'Geist', sans-serif;
    font-size: 18px;
    font-weight: 500;
    letter-spacing: -0.4px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.confirm-payment-btn:hover {
    background: #3A3A39;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(34, 34, 33, 0.15);
}

.confirm-payment-btn:active {
    transform: translateY(0);
}

.confirm-payment-btn:disabled {
    background: #898683;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* Custom Notification System */
.custom-notification {
    position: fixed;
    top: 100px;
    right: 80px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 20px 24px;
    background: #FFFFFF;
    border-radius: 12px;
    border: 1px solid #EDECE7;
    box-shadow: 0 8px 24px rgba(34, 34, 33, 0.1);
    max-width: 400px;
    transform: translateX(120%);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: auto;
}

.custom-notification.show {
    transform: translateX(0);
}

.custom-notification-icon {
    flex-shrink: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.custom-notification-icon.success {
    background: rgba(81, 207, 102, 0.1);
    color: #51CF66;
}

.custom-notification-icon.error {
    background: rgba(255, 107, 107, 0.1);
    color: #FF6B6B;
}

.custom-notification-icon.warning {
    background: rgba(240, 173, 78, 0.1);
    color: #F0AD4E;
}

.custom-notification-icon.info {
    background: rgba(114, 112, 111, 0.1);
    color: #72706F;
}

.custom-notification-content {
    flex: 1;
}

.custom-notification-title {
    font-family: 'Geist', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #222221;
    margin: 0 0 4px 0;
    letter-spacing: -0.2px;
}

.custom-notification-message {
    font-family: 'Geist', sans-serif;
    font-size: 14px;
    font-weight: 400;
    color: #72706F;
    margin: 0;
    line-height: 1.4;
    letter-spacing: -0.2px;
}

.custom-notification-close {
    flex-shrink: 0;
    background: none;
    border: none;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: #898683;
    transition: color 0.2s ease;
    border-radius: 4px;
    padding: 0;
}

.custom-notification-close:hover {
    color: #222221;
    background: #F5F4F2;
}

/* Progress bar for auto-dismiss */
.custom-notification-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: rgba(34, 34, 33, 0.1);
    border-radius: 0 0 12px 12px;
    overflow: hidden;
}

.custom-notification-progress-bar {
    height: 100%;
    background: #222221;
    width: 100%;
    transform: translateX(-100%);
    transition: transform 5s linear;
}

.custom-notification.show .custom-notification-progress-bar {
    transform: translateX(0);
}


/* Responsive Design */
@media (min-width: 744px) and (max-width: 1279px) {
    .back-button-container{
        margin-left: 64px;
        margin-right: 64px;
    }
    .page-header{
        margin-left: 64px;
        margin-right: 64px;
        margin-bottom: 64px;
        gap: 32px;
        max-width: 80%;
    }
    .order-section{
        margin-left: 64px;
        margin-right: 64px;
        margin-bottom: 64px;
        gap: 48px;
        flex-direction: column;
        max-width: 80%;
    }
    .page-title h1{
        font-size: 40px;
    }
    .card {
        padding: 24px 20px;
    }
    .card h2 {
        font-size: 20px;
    }
    .special-request h2 {
        font-size: 20px;
    }
    .card p {
        font-size: 18px;
    }
    
    /* Tablet adjustments */
    .order-details,
    .order-summary {
        width: 100%;
    }
    
    .order-summary-card,
    .contact-card,
    .payment-card {
        padding: 24px;
    }

    .custom-notification {
        right: 64px;
        max-width: 350px;
    }
}

@media (min-width: 320px) and (max-width: 743px) {
    .back-button-container{
        margin-top: 24px;
        margin-bottom: 32px;
        margin-left: 20px;
        margin-right: 20px;
    }
    .page-header{
        margin-left: 20px;
        margin-right: 20px;
        margin-bottom: 32px;
        gap: 32px;
    }
    .order-section{
        margin-left: 20px;
        margin-right: 20px;
        margin-bottom: 32px;
        gap: 32px;
        flex-direction: column;
    }
    .page-title h1{
        font-size: 24px;
    }
    .card {
        padding: 20px 16px;
    }
    .card h2 {
        font-size: 18px;
    }
    .special-request h2 {
        font-size: 18px;
    }
    .card p {
        font-size: 18px;
    }
    
    /* Mobile adjustments */
    .order-details,
    .order-summary {
        width: 100%;
    }
    
    .order-summary {
        gap: 32px;
    }
    
    .order-summary-card,
    .contact-card,
    .payment-card {
        padding: 20px 16px;
        gap: 24px;
    }
    
    .summary-title {
        font-size: 18px;
    }
    
    .confirm-payment-btn {
        padding: 16px 24px;
        font-size: 16px;
    }
    
    .payment-details {
        padding: 16px;
    }
    
    .total-label {
        font-size: 16px;
    }
    
    .total-amount {
        font-size: 18px;
    }
    
    .contact-field input {
        padding: 10px 14px;
        font-size: 15px;
    }
    
    .special-request textarea {
        min-height: 100px;
        font-size: 15px;
        padding: 10px 12px;
    }

    .custom-notification {
        top: 80px;
        right: 20px;
        left: 20px;
        max-width: calc(100% - 40px);
    }
}