/* Citytech Gown Modal Styling */
body.gown-modal-open {
    overflow: hidden !important;
}

.citytech-gown-modal-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
    display: none;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
}

.citytech-gown-modal-container.active {
    display: flex !important;
}

.citytech-gown-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    z-index: 1;
}

.citytech-gown-modal-content {
    position: relative;
    z-index: 2;
    background: #ffffff;
    width: 92%;
    max-width: 560px;
    border-radius: 20px;
    padding: 30px 32px;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.28);
    box-sizing: border-box;
    max-height: 92vh;
    overflow-y: auto;
    animation: gownModalFadeIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes gownModalFadeIn {
    0% {
        opacity: 0;
        transform: scale(0.95) translateY(8px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

/* Modal Header */
.gown-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
    position: relative;
}

.gown-modal-title {
    font-size: 24px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    font-family: inherit;
    line-height: 1.2;
}

.gown-modal-close {
    background: transparent;
    border: none;
    cursor: pointer;
    color: #6b7280;
    padding: 2px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s ease, transform 0.15s ease;
}

.gown-modal-close:hover {
    color: #111827;
    transform: scale(1.08);
}

.gown-modal-close svg {
    display: block;
    width: 26px;
    height: 26px;
}

/* Product Summary Section */
.gown-product-summary {
    display: flex;
    gap: 20px;
    align-items: flex-start;
    margin-bottom: 24px;
    padding-bottom: 20px;
    border-bottom: 1px solid #f3f4f6;
}

.gown-product-image-box {
    width: 130px;
    height: 130px;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 6px;
    box-sizing: border-box;
    flex-shrink: 0;
    background: #ffffff;
    overflow: hidden;
}

.gown-product-image-box img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: block;
}

.gown-product-info-box {
    flex: 1;
    min-width: 0;
    text-align: left;
}

.gown-product-name {
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    text-transform: uppercase;
    margin: 0 0 6px 0;
    line-height: 1.35;
    word-break: break-word;
}

.gown-product-sku-row,
.gown-product-size-row {
    font-size: 14px;
    color: #6b7280;
    margin-bottom: 4px;
    line-height: 1.3;
}

.gown-product-sku-row .gown-label,
.gown-product-size-row .gown-label {
    margin-right: 4px;
    font-weight: 500;
}

.gown-product-sku-row .gown-value,
.gown-product-size-row .gown-value {
    color: #4b5563;
    font-weight: 500;
}

.gown-product-price {
    font-size: 22px;
    font-weight: 700;
    color: #111827;
    margin-top: 10px;
    line-height: 1.2;
}

/* Form Groups & Inputs */
.gown-custom-options-form {
    text-align: left;
}

.gown-form-group {
    margin-bottom: 16px;
}

.gown-form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 6px;
}

.gown-form-input {
    width: 100%;
    box-sizing: border-box;
    height: 48px;
    padding: 10px 14px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 15px;
    color: #111827;
    background: #f9fafb;
    outline: none;
    transition: border-color 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
    font-family: inherit;
}

.gown-form-input::placeholder {
    color: #9ca3af;
    opacity: 1;
}

.gown-form-input:focus {
    border-color: #111827;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(17, 24, 39, 0.08);
}

.gown-form-input.gown-input-error {
    border-color: #ef4444 !important;
    background: #fef2f2 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.12) !important;
}

.gown-error-message {
    color: #e02b27;
    font-size: 13.5px;
    font-weight: 500;
    margin-top: 6px;
    line-height: 1.35;
    display: block;
}

.gown-field-note {
    font-size: 13px;
    color: #6b7280;
    margin: 5px 0 0 0;
    line-height: 1.3;
}

/* Two-column Row for Initials & Name on Cap */
.gown-form-row {
    display: flex;
    gap: 14px;
    margin-bottom: 6px;
}

.gown-half-col {
    flex: 1;
    min-width: 0;
    margin-bottom: 12px;
}

/* Submit Action Button */
.gown-form-actions {
    margin-top: 22px;
}

.gown-submit-btn {
    width: 100%;
    height: 52px;
    background: #0c1017;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease, opacity 0.2s ease, transform 0.1s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: inherit;
    outline: none;
    letter-spacing: 0.2px;
}

.gown-submit-btn:hover:not(:disabled) {
    background: #1f2937;
}

.gown-submit-btn:active:not(:disabled) {
    transform: translateY(1px);
}

.gown-submit-btn:disabled {
    opacity: 0.65;
    cursor: not-allowed;
}

.gown-submit-btn.loading span::after {
    content: " ...";
    animation: gownDots 1s steps(4, end) infinite;
}

@keyframes gownDots {
    0%, 20% { content: " ."; }
    40% { content: " .."; }
    60%, 100% { content: " ..."; }
}

/* Responsive adjustments */
@media screen and (max-width: 600px) {
    .citytech-gown-modal-content {
        padding: 22px 18px;
        border-radius: 16px;
        width: 95%;
    }

    .gown-modal-title {
        font-size: 20px;
    }

    .gown-product-summary {
        gap: 14px;
        margin-bottom: 18px;
        padding-bottom: 16px;
    }

    .gown-product-image-box {
        width: 100px;
        height: 100px;
    }

    .gown-product-name {
        font-size: 14px;
    }

    .gown-product-price {
        font-size: 18px;
        margin-top: 6px;
    }

    .gown-form-row {
        flex-direction: column;
        gap: 0;
    }

    .gown-form-input {
        height: 44px;
        font-size: 14px;
    }

    .gown-submit-btn {
        height: 48px;
        font-size: 15px;
    }
}
