/**
 * Japebo Order Tracking Styles
 * 
 * Custom styling for the [japebo_track_order_form] shortcode.
 * Replaces default WooCommerce styling.
 */

.jot-track-order-form {
    max-width: 480px;
    margin: 0 auto;
    padding: 0;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    font-family: inherit;
}

.jot-track-order-form .form-row {
    margin: 0 0 16px;
    padding: 0;
    width: 100%;
    float: none;
    display: block;
}

.jot-track-order-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 600;
    font-size: 14px;
    color: #333 !important;
    line-height: 1.4;
}

.jot-track-order-form label .required {
    color: #d63638;
    text-decoration: none;
}

.jot-track-order-form input[type="text"],
.jot-track-order-form input[type="email"] {
    width: 100%;
    padding: 12px 14px;
    border: 1px solid #ccc;
    border-radius: 6px;
    box-sizing: border-box;
    font-size: 15px;
    color: #333;
    background-color: #fff;
    line-height: 1.5;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    height: auto;
    /* Ensure height isn't forced by theme */
}

.jot-track-order-form input[type="text"]:focus,
.jot-track-order-form input[type="email"]:focus {
    border-color: #007cba;
    box-shadow: 0 0 0 1px #007cba;
    outline: none;
}

.jot-track-order-submit-button {
    display: inline-block;
    width: 100%;
    padding: 14px 20px;
    font-size: 16px;
    font-weight: 600;
    color: #ffffff !important;
    /* Force white text */
    background-color: #1a1a1a;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.2s ease;
    line-height: 1.2;
    margin-top: 8px;
}

.jot-track-order-submit-button:hover {
    background-color: #4dae65;
}

/* Error Popup Styles */
.jot-error-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    animation: jotFadeIn 0.3s forwards;
}

.jot-error-popup {
    background: white;
    padding: 30px;
    border-radius: 12px;
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.2);
    position: relative;
    transform: translateY(20px);
    animation: jotSlideUp 0.3s 0.1s forwards;
}

.jot-error-icon {
    width: 60px;
    height: 60px;
    margin: 0 auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fee2e2;
    border-radius: 50%;
    color: #dc2626;
}

.jot-error-icon svg {
    width: 32px;
    height: 32px;
}

.jot-error-title {
    font-size: 20px;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 10px;
}

.jot-error-message {
    color: #666;
    margin-bottom: 24px;
    line-height: 1.5;
}

.jot-error-close {
    background: #1a1a1a;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    width: 100%;
}

.jot-error-close:hover {
    background: #333;
}

@keyframes jotFadeIn {
    to {
        opacity: 1;
    }
}

@keyframes jotSlideUp {
    to {
        transform: translateY(0);
    }
}

.jot-track-order-submit-button:focus {
    outline: 2px solid #007cba;
    outline-offset: 2px;
}

/* Clearfix */
.jot-track-order-form::after {
    content: "";
    display: table;
    clear: both;
}