/**
 * Rubies Preorder System CSS
 *
 * Handles all styling for the preorder system.
 */

/* Date field styles */
#date_custom_checkout_field {
    margin-bottom: 20px;
    padding: 15px;
    background-color: #f8f8f8;
    border-radius: 4px;
}

#date_custom_checkout_field h2 {
    margin-top: 0;
    font-size: 1.2em;
}

/* Apply date button styles */
.apply-discount {
    margin-bottom: 20px;
}

.apply-discount button {
    background-color: #3d9cd2;
    color: #fff;
}

.apply-discount button:hover {
    background-color: #2d8abf;
}

/* Clear date button styles */
.clear-date-button {
    margin-bottom: 20px;
}

.clear-date-button a {
    background-color: #f44336;
    color: #fff;
}

.clear-date-button a:hover {
    background-color: #d32f2f;
}

/* Instructions message styles */
.custom-checkout-message {
    padding: 15px;
    background-color: #fffacd;
    border-left: 4px solid #ffd700;
    margin-bottom: 20px;
    border-radius: 0 4px 4px 0;
}

.custom-checkout-message .apply {
    color: #3d9cd2;
}

/* Remove discount button styles */
.remove-discount-button {
    margin-left: 10px;
    font-size: 0.8em !important;
    padding: 0.3em 0.6em !important;
    background-color: #f44336 !important;
    color: #fff !important;
}

.remove-discount-button:hover {
    background-color: #d32f2f !important;
}

/* Availability messages styles */
.backorder-warning {
    color: #f97c00;
    font-weight: bold;
}

.stock-preorder-available {
    color: #398f14;
    font-weight: bold;
}

.preorder-available {
    color: #f97c00;
    font-weight: bold;
}

.stock-available {
    color: #398f14;
    font-weight: bold;
}

.stock-unavailable {
    color: #e2401c;
    font-weight: bold;
}

/* Datepicker blocked date styling */
.blocked-date .ui-state-default {
    background: #f8d7da !important;
    color: #721c24 !important;
    cursor: not-allowed;
}

.weekend-date .ui-state-default {
    background: #f0f0f0 !important;
    color: #999 !important;
    cursor: not-allowed;
}

/* Admin styles */
.wrap .preorder-user-management {
    margin-top: 30px;
    border-top: 1px solid #ccc;
    padding-top: 20px;
}

.wrap .preorder-blocked-periods {
    margin-top: 30px;
    border-top: 1px solid #ccc;
    padding-top: 20px;
}

.wrap .add-user-form,
.wrap .current-users {
    margin: 20px 0;
}

.wrap .current-users table {
    margin-top: 10px;
}

#rubies-blocked-periods .form-table {
    max-width: 600px;
}

#rubies-blocked-periods .form-table input[type="date"],
#rubies-blocked-periods .form-table input[type="text"] {
    min-width: 250px;
}
