/**
 * Customer-facing "My Licenses" My Account Portal Styles
 * Light & Composition License Manager
 */

.lc-my-account-portal {
    margin: 1.5rem 0 2.5rem;
    font-family: inherit;
    color: #1e293b;
}

.lc-my-account-portal * {
    box-sizing: border-box;
}

.lc-portal-header {
    margin-bottom: 1.75rem;
}

.lc-portal-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.01em;
}

.lc-portal-subtitle {
    font-size: 0.95rem;
    color: #64748b;
    margin: 0;
    line-height: 1.5;
}

/* License Card Container */
.lc-license-cards-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.lc-license-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 2px 6px -1px rgba(0, 0, 0, 0.05), 0 1px 4px -1px rgba(0, 0, 0, 0.03);
    transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.lc-license-card:hover {
    border-color: #cbd5e1;
    box-shadow: 0 4px 12px -2px rgba(0, 0, 0, 0.07), 0 2px 6px -2px rgba(0, 0, 0, 0.04);
}

/* Card Header */
.lc-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 0.75rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f1f5f9;
    margin-bottom: 1.25rem;
}

.lc-card-title-wrap {
    flex: 1;
    min-width: 200px;
}

.lc-product-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0 0 0.25rem 0;
}

.lc-card-meta {
    font-size: 0.85rem;
    color: #64748b;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.lc-card-meta a {
    color: #2563eb;
    text-decoration: none;
}

.lc-card-meta a:hover {
    text-decoration: underline;
}

/* Status Badges */
.lc-status-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.65rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    line-height: 1;
}

.lc-status-badge::before {
    content: "";
    display: inline-block;
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.lc-status-badge--active {
    background-color: #ecfdf5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}
.lc-status-badge--active::before {
    background-color: #10b981;
}

.lc-status-badge--expired {
    background-color: #fffbeb;
    color: #92400e;
    border: 1px solid #fde68a;
}
.lc-status-badge--expired::before {
    background-color: #f59e0b;
}

.lc-status-badge--revoked,
.lc-status-badge--suspended,
.lc-status-badge--inactive {
    background-color: #fef2f2;
    color: #991b1b;
    border: 1px solid #fecaca;
}
.lc-status-badge--revoked::before,
.lc-status-badge--suspended::before,
.lc-status-badge--inactive::before {
    background-color: #ef4444;
}

/* Key Display Bar */
.lc-key-row {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
}

.lc-key-label {
    font-size: 0.8rem;
    text-transform: uppercase;
    font-weight: 600;
    letter-spacing: 0.05em;
    color: #64748b;
}

.lc-key-val-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.lc-license-key-code {
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 0.95rem;
    font-weight: 600;
    color: #0f172a;
    background: #ffffff;
    padding: 0.35rem 0.65rem;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    letter-spacing: 0.04em;
    user-select: all;
}

.lc-copy-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    background-color: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 0.35rem 0.75rem;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s ease;
}

.lc-copy-btn:hover {
    background-color: #f1f5f9;
    color: #0f172a;
    border-color: #94a3b8;
}

.lc-copy-btn.copied {
    background-color: #ecfdf5;
    color: #065f46;
    border-color: #a7f3d0;
}

.lc-copy-btn svg {
    width: 14px;
    height: 14px;
    stroke: currentColor;
    fill: none;
}

/* Slots Progress Meter */
.lc-slot-section {
    margin-bottom: 1.25rem;
}

.lc-slot-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    margin-bottom: 0.4rem;
    color: #475569;
}

.lc-slot-count {
    font-weight: 600;
    color: #0f172a;
}

.lc-meter-track {
    width: 100%;
    height: 8px;
    background-color: #f1f5f9;
    border-radius: 9999px;
    overflow: hidden;
}

.lc-meter-fill {
    height: 100%;
    background-color: #2563eb;
    border-radius: 9999px;
    transition: width 0.3s ease;
}

.lc-meter-fill--full {
    background-color: #f59e0b;
}

/* Authorized Domains Table */
.lc-domains-section {
    margin-top: 1.25rem;
}

.lc-domains-heading {
    font-size: 0.9rem;
    font-weight: 600;
    color: #334155;
    margin: 0 0 0.5rem 0;
}

.lc-domains-table-wrap {
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
}

.lc-domains-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
    margin: 0;
}

.lc-domains-table th {
    background-color: #f8fafc;
    text-align: left;
    padding: 0.6rem 0.85rem;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: #64748b;
    border-bottom: 1px solid #e2e8f0;
}

.lc-domains-table td {
    padding: 0.65rem 0.85rem;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    vertical-align: middle;
}

.lc-domains-table tr:last-child td {
    border-bottom: none;
}

.lc-domain-name {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 500;
    color: #0f172a;
}

.lc-domain-icon {
    width: 15px;
    height: 15px;
    color: #94a3b8;
    flex-shrink: 0;
}

.lc-deactivate-btn {
    display: inline-block;
    background-color: transparent;
    color: #dc2626;
    border: 1px solid #fecaca;
    padding: 0.3rem 0.65rem;
    font-size: 0.8rem;
    font-weight: 500;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.15s ease;
    line-height: 1.2;
}

.lc-deactivate-btn:hover {
    background-color: #fef2f2;
    color: #b91c1c;
    border-color: #f87171;
}

.lc-empty-domains {
    background-color: #f8fafc;
    border: 1px dashed #cbd5e1;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    font-size: 0.875rem;
    color: #64748b;
    margin: 0.5rem 0 0 0;
}

/* Empty State Card */
.lc-empty-portal-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.lc-empty-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 1rem;
    color: #94a3b8;
}

.lc-empty-title {
    font-size: 1.15rem;
    font-weight: 600;
    color: #0f172a;
    margin: 0 0 0.5rem 0;
}

.lc-empty-desc {
    font-size: 0.95rem;
    color: #64748b;
    margin: 0 0 1.5rem 0;
    line-height: 1.5;
}

.lc-portal-footer {
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #e2e8f0;
    font-size: 0.875rem;
    color: #64748b;
    line-height: 1.6;
}

.lc-portal-footer a {
    color: #2563eb;
    text-decoration: underline;
}

@media (max-width: 640px) {
    .lc-license-card {
        padding: 1.25rem 1rem;
    }
    .lc-key-row {
        flex-direction: column;
        align-items: flex-start;
    }
    .lc-key-val-wrap {
        width: 100%;
        justify-content: space-between;
    }
    .lc-domains-table th:nth-child(2),
    .lc-domains-table td:nth-child(2) {
        text-align: right;
    }
}
