/**
 * Paid Member Subscriptions - Shortcode Styles
 * Modern, clean styling for all shortcode views
 */

/* Common styles for all shortcodes */
.pms-form,
.pms-account-subscription-details-table,
.pms-payment-history-table,
.pms-subscriptions-table {
    width: 100%;
    max-width: 800px;
    margin: 0 auto 30px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
    color: #333;
    line-height: 1.5;
}

/* Table styling */
.pms-account-subscription-details-table,
.pms-payment-history-table,
.pms-subscriptions-table {
    border-collapse: collapse;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
    border-radius: 8px;
    overflow: hidden;
    background-color: #fff;
}

.pms-account-subscription-details-table tbody tr,
.pms-payment-history-table tbody tr,
.pms-subscriptions-table tbody tr {
    border-bottom: 1px solid #f0f0f0;
}

.pms-account-subscription-details-table tbody tr:last-child,
.pms-payment-history-table tbody tr:last-child,
.pms-subscriptions-table tbody tr:last-child {
    border-bottom: none;
}

.pms-account-subscription-details-table td,
.pms-payment-history-table td,
.pms-payment-history-table th,
.pms-subscriptions-table td,
.pms-subscriptions-table th {
    padding: 14px 20px;
    text-align: left;
}

.pms-account-subscription-details-table td:first-child,
.pms-payment-history-table th,
.pms-subscriptions-table th {
    font-weight: 600;
    width: 35%;
    background-color: #f8f9fa;
}

/* Status colors */
.status-active {
    color: #28a745;
    font-weight: 600;
}

.status-expired {
    color: #dc3545;
    font-weight: 600;
}

.status-pending {
    color: #ffc107;
    font-weight: 600;
}

.status-canceled {
    color: #6c757d;
    font-weight: 600;
}

/* Form styling */
.pms-form {
    padding: 30px;
    background-color: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.pms-form-fields-wrapper {
    list-style: none;
    padding: 0;
    margin: 0 0 20px 0;
}

.pms-field {
    margin-bottom: 20px;
    position: relative;
}

.pms-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #444;
}

.pms-field input[type="text"],
.pms-field input[type="email"],
.pms-field input[type="password"],
.pms-field input[type="number"],
.pms-field select,
.pms-field textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background-color: #f9f9f9;
    font-size: 16px;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.pms-field input[type="text"]:focus,
.pms-field input[type="email"]:focus,
.pms-field input[type="password"]:focus,
.pms-field input[type="number"]:focus,
.pms-field select:focus,
.pms-field textarea:focus {
    border-color: #4a90e2;
    box-shadow: 0 0 0 3px rgba(74, 144, 226, 0.1);
    outline: none;
    background-color: #fff;
}

/* Checkbox styling */
.pms-field input[type="checkbox"] {
    margin-right: 8px;
    vertical-align: middle;
}

/* Submit button styling */
.pms-form-submit,
.pms-form input[type="submit"] {
    background-color: #4a90e2;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
}

.pms-form-submit:hover,
.pms-form input[type="submit"]:hover {
    background-color: #3a7bc8;
}

/* Error styling */
.pms-field-error label {
    color: #dc3545;
}

/* Registration Message */
.pms-registration-message {
    background-color: #e7f5ff;
    border-left: 4px solid #4a90e2;
    padding: 12px 15px;
    margin-bottom: 20px;
    border-radius: 3px;
    color: #333;
    font-size: 14px;
    line-height: 1.5;
}

.pms-field-error input,
.pms-field-error select,
.pms-field-error textarea {
    border-color: #dc3545;
    background-color: #fff8f8;
}

.pms-field-error-message {
    color: #dc3545;
    font-size: 14px;
    margin-top: 5px;
    display: block;
}

/* Subscription plans styling */
.pms-subscription-plan {
    margin-bottom: 15px;
    padding: 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    transition: all 0.3s;
}

.pms-subscription-plan:hover {
    border-color: #4a90e2;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.pms-subscription-plan input[type="radio"] {
    margin-right: 10px;
}

.pms-subscription-plan label {
    font-weight: 600;
    font-size: 16px;
}

.pms-subscription-plan-description {
    margin-top: 5px;
    color: #666;
    padding-left: 25px;
}

.pms-subscription-plan-price {
    font-weight: 600;
    color: #4a90e2;
    padding-left: 25px;
}

/* Account actions styling */
.pms-account-subscription-action-link {
    display: inline-block;
    margin-right: 15px;
    padding: 8px 15px;
    border-radius: 4px;
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    transition: all 0.3s;
}

.pms-account-subscription-action-link__cancel {
    color: #dc3545;
    border: 1px solid #dc3545;
    background-color: transparent;
}

.pms-account-subscription-action-link__cancel:hover {
    background-color: #dc3545;
    color: white;
}

.pms-account-subscription-action-link__renew,
.pms-account-subscription-action-link__retry {
    color: #28a745;
    border: 1px solid #28a745;
    background-color: transparent;
}

.pms-account-subscription-action-link__renew:hover,
.pms-account-subscription-action-link__retry:hover {
    background-color: #28a745;
    color: white;
}

.pms-account-subscription-action-link__abandon {
    color: #6c757d;
    border: 1px solid #6c757d;
    background-color: transparent;
}

.pms-account-subscription-action-link__abandon:hover {
    background-color: #6c757d;
    color: white;
}

.pms-account-subscription-action-link__upgrade {
    color: #4a90e2;
    border: 1px solid #4a90e2;
    background-color: transparent;
}

.pms-account-subscription-action-link__upgrade:hover {
    background-color: #4a90e2;
    color: white;
}

/* Payment method section */
.pms-account-subscription-details-table__payment-method {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .pms-form {
        padding: 20px;
    }
    
    .pms-account-subscription-details-table td,
    .pms-payment-history-table td,
    .pms-payment-history-table th,
    .pms-subscriptions-table td,
    .pms-subscriptions-table th {
        padding: 10px 15px;
    }
    
    .pms-account-subscription-details-table td:first-child,
    .pms-payment-history-table th,
    .pms-subscriptions-table th {
        width: 40%;
    }
    
    .pms-account-subscription-action-link {
        display: block;
        margin-bottom: 10px;
        text-align: center;
    }
}

@media (max-width: 480px) {
    .pms-account-subscription-details-table,
    .pms-payment-history-table,
    .pms-subscriptions-table {
        display: block;
        overflow-x: auto;
    }
    
    .pms-form-submit,
    .pms-form input[type="submit"] {
        width: 100%;
    }
}
