/**
 * License Manager Pro - Frontend Styles
 */

.lmp-application-page {
    padding: 60px 20px;
    min-height: 60vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.lmp-application-page .page-title {
    margin: 0 0 15px;
    color: #1d2327;
    font-size: 36px;
    font-weight: 700;
    text-align: center;
}

.lmp-application-page .page-description {
    margin: 0 0 40px;
    color: #646970;
    font-size: 16px;
    text-align: center;
}

.lmp-actions {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.lmp-btn-large {
    padding: 16px 40px;
    font-size: 16px;
    border-radius: 8px;
    width: auto;
}

.lmp-btn-icon {
    font-size: 20px;
}

/* Modal */
.lmp-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 999999;
}

.lmp-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(3px);
}

.lmp-modal-content {
    position: relative;
    width: 90%;
    max-width: 600px;
    max-height: 90vh;
    margin: 5vh auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    z-index: 999999;
}

.lmp-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px;
    border-bottom: 1px solid #dcdcde;
}

.lmp-modal-title {
    margin: 0;
    color: #1d2327;
    font-size: 22px;
    font-weight: 600;
}

.lmp-modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: #f0f0f1;
    border-radius: 6px;
    font-size: 28px;
    line-height: 1;
    color: #646970;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.lmp-modal-close:hover {
    background: #dcdcde;
    color: #1d2327;
}

.lmp-modal-body {
    padding: 24px;
    overflow-y: auto;
    max-height: calc(90vh - 120px);
}

.lmp-modal-actions {
    display: flex;
    gap: 12px;
    margin-top: 30px;
}

.lmp-modal-actions .lmp-btn {
    flex: 1;
}

.lmp-btn-secondary {
    background: #f6f7f7;
    color: #1d2327;
    border: 1px solid #dcdcde;
}

.lmp-btn-secondary:hover {
    background: #f0f0f1;
    border-color: #c3c4c7;
}

.lmp-application-form {
    max-width: 600px;
    margin: 0 auto;
    padding: 30px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.lmp-application-form h2 {
    margin-top: 0;
    margin-bottom: 25px;
    text-align: center;
    color: #1d2327;
    font-size: 28px;
    font-weight: 600;
}

.lmp-form-group {
    margin-bottom: 20px;
}

.lmp-form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #1d2327;
    font-size: 14px;
}

.lmp-help-text {
    display: block;
    margin-top: 5px;
    font-size: 12px;
    color: #646970;
    line-height: 1.4;
}

.lmp-help-text strong {
    color: #1d2327;
}

.lmp-form-group label .required {
    color: #d63638;
}

.lmp-input,
.lmp-textarea {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    font-size: 14px;
    line-height: 1.5;
    transition: border-color 0.3s;
    box-sizing: border-box;
}

.lmp-input:focus,
.lmp-textarea:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34, 113, 177, 0.1);
}

.lmp-textarea {
    resize: vertical;
    min-height: 100px;
}

.lmp-input::placeholder,
.lmp-textarea::placeholder {
    color: #a7aaad;
}

.lmp-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 24px;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    width: 100%;
}

.lmp-btn-primary {
    background: #2271b1;
    color: #fff;
}

.lmp-btn-primary:hover {
    background: #135e96;
}

.lmp-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.lmp-btn .dashicons {
    font-size: 16px;
}

.lmp-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 4px;
    font-size: 14px;
}

.lmp-message.success {
    background: #edfaef;
    color: #00a32a;
    border-left: 4px solid #00a32a;
}

.lmp-message.error {
    background: #fbeaea;
    color: #d63638;
    border-left: 4px solid #d63638;
}

.lmp-message.info {
    background: #e5f5fa;
    color: #0073aa;
    border-left: 4px solid #0073aa;
}

/* Loading */
.lmp-loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 2px solid #f3f3f3;
    border-top: 2px solid #2271b1;
    border-radius: 50%;
    animation: lmp-spin 1s linear infinite;
}

@keyframes lmp-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Orders Page */
.lmp-orders-page {
    padding: 40px 20px;
    min-height: 60vh;
}

.lmp-orders-page .page-title {
    margin: 0 0 30px;
    color: #1d2327;
    font-size: 36px;
    font-weight: 700;
    text-align: center;
}

/* Empty State */
.lmp-empty-state {
    text-align: center;
    padding: 80px 20px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.lmp-empty-icon {
    font-size: 64px;
    margin-bottom: 20px;
}

.lmp-empty-title {
    margin: 0 0 10px;
    font-size: 24px;
    color: #1d2327;
}

.lmp-empty-desc {
    margin: 0 0 30px;
    font-size: 16px;
    color: #646970;
}

/* Orders List */
.lmp-orders-list {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

/* Order Card */
.lmp-order-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    overflow: hidden;
    transition: box-shadow 0.3s;
}

.lmp-order-card:hover {
    box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}

.lmp-order-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 24px;
    border-bottom: 1px solid #dcdcde;
    gap: 20px;
}

.lmp-order-info {
    flex: 1;
}

.lmp-product-name {
    margin: 0 0 12px;
    font-size: 20px;
    font-weight: 600;
    color: #1d2327;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.lmp-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 500;
}

.lmp-badge-warning {
    background: #fef3e7;
    color: #d48806;
}

.lmp-badge-danger {
    background: #fbeaea;
    color: #d63638;
}

.lmp-order-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 24px;
}

.lmp-order-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: #646970;
}

.lmp-icon {
    font-size: 16px;
}

.lmp-order-status {
    flex-shrink: 0;
}

.lmp-status {
    display: inline-block;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
}

.lmp-status-success {
    background: #edfaef;
    color: #00a32a;
}

.lmp-status-info {
    background: #e5f5fa;
    color: #0073aa;
}

.lmp-status-warning {
    background: #fef3e7;
    color: #d48806;
}

.lmp-status-danger {
    background: #fbeaea;
    color: #d63638;
}

/* Order Body */
.lmp-order-body {
    padding: 24px;
}

.lmp-order-section {
    margin-bottom: 24px;
}

.lmp-order-section:last-child {
    margin-bottom: 0;
}

.lmp-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 16px;
    flex-wrap: wrap;
}

.lmp-section-title {
    margin: 0;
    font-size: 16px;
    font-weight: 600;
    color: #1d2327;
    display: flex;
    align-items: center;
    gap: 8px;
}

.lmp-section-icon {
    font-size: 18px;
}

.lmp-domain-count {
    font-size: 14px;
    color: #646970;
    font-weight: normal;
}

/* Domain List */
.lmp-domain-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.lmp-empty-domains {
    padding: 20px;
    background: #f6f7f7;
    border-radius: 8px;
    text-align: center;
    color: #646970;
}

.lmp-domain-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px;
    background: #f6f7f7;
    border-radius: 8px;
    gap: 16px;
}

.lmp-domain-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.lmp-domain-name {
    font-size: 15px;
    font-weight: 500;
    color: #1d2327;
}

.lmp-domain-sub {
    font-size: 13px;
    color: #646970;
}

/* License Key */
.lmp-license-key-box {
    background: #f6f7f7;
    border-radius: 8px;
    padding: 20px;
}

.lmp-license-key-display {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
}

.lmp-license-key {
    flex: 1;
    display: block;
    padding: 12px 16px;
    background: #fff;
    border: 1px solid #dcdcde;
    border-radius: 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 13px;
    color: #1d2327;
    word-break: break-all;
}

/* Order Footer */
.lmp-order-footer {
    padding: 20px 24px;
    border-top: 1px solid #dcdcde;
    background: #f6f7f7;
}

.lmp-order-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.lmp-order-actions .lmp-btn {
    width: auto;
    flex-shrink: 0;
}

/* Buttons */
.lmp-btn-small {
    padding: 8px 16px;
    font-size: 13px;
}

.lmp-btn-text {
    background: transparent;
    border: 1px solid transparent;
    color: #1d2327;
    padding: 6px 12px;
}

.lmp-btn-text:hover {
    background: #f6f7f7;
    border-color: #dcdcde;
}

.lmp-btn-text .lmp-icon {
    font-size: 14px;
}

/* Responsive */
@media (max-width: 768px) {
    .lmp-application-page {
        padding: 40px 20px;
    }

    .lmp-application-page .page-title {
        font-size: 28px;
    }

    .lmp-application-page .page-description {
        font-size: 14px;
    }

    .lmp-btn-large {
        padding: 14px 32px;
        font-size: 15px;
    }

    .lmp-modal-content {
        width: 95%;
        margin: 10px auto;
        max-height: 95vh;
    }

    .lmp-modal-header {
        padding: 20px;
    }

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

    .lmp-modal-body {
        padding: 20px;
    }

    .lmp-modal-actions {
        flex-direction: column;
    }

    .lmp-modal-actions .lmp-btn {
        width: 100%;
    }

    .lmp-application-form {
        padding: 20px;
    }

    .lmp-application-form h2 {
        font-size: 24px;
    }

    .lmp-orders-page {
        padding: 20px;
    }

    .lmp-orders-page .page-title {
        font-size: 28px;
    }

    .lmp-order-header {
        padding: 16px;
        flex-direction: column;
    }

    .lmp-product-name {
        font-size: 18px;
    }

    .lmp-order-meta {
        gap: 16px;
        flex-direction: column;
    }

    .lmp-order-body {
        padding: 16px;
    }

    .lmp-section-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .lmp-domain-item {
        flex-direction: column;
        align-items: flex-start;
    }

    .lmp-domain-item .lmp-btn {
        align-self: flex-start;
    }

    .lmp-license-key-display {
        flex-direction: column;
        align-items: stretch;
    }

    .lmp-order-footer {
        padding: 16px;
    }

    .lmp-order-actions {
        flex-direction: column;
    }

    .lmp-order-actions .lmp-btn {
        width: 100%;
    }

    .lmp-empty-state {
        padding: 40px 20px;
    }

    .lmp-empty-icon {
        font-size: 48px;
    }
}

