/* Variables */
:root {
    --color-primary: #007bff;
    --color-secondary: #6c757d;
    --color-success: #28a745;
    --color-danger: #dc3545;
    --color-warning: #ffc107;
    --color-info: #17a2b8;
    --color-light: #f8f9fa;
    --color-dark: #343a40;
    --color-grey-1: #E1E1E1;
}

/* Text colors */
.text-primary {
    color: var(--color-primary);
}

.text-secondary {
    color: var(--color-secondary);
}

.text-success {
    color: var(--color-success);
}

.text-danger {
    color: var(--color-danger);
}

.text-warning {
    color: var(--color-warning);
}

.text-info {
    color: var(--color-info);
}

.text-light {
    color: var(--color-light);
}

.text-dark {
    color: var(--color-dark);
}

/* Table auto-width fix */
table.wp-list-table.generators,
table.wp-list-table.generatoren,
table.wp-list-table.licensekeys,
table.wp-list-table.lizenzschlssel {
    table-layout: auto !important;
}

/* License table */
table.wp-list-table.licensekeys td.source.column-source>span,
table.wp-list-table.lizenzschlssel td.source.column-source>span {
    font-size: 2em;
}

.lmfwc-license-key-show,
.lmfwc-license-key-hide {
    cursor: pointer;
}

table.wp-list-table.licensekeys td.source.column-source,
table.wp-list-table.lizenzschlssel td.source.column-source,
table.wp-list-table.licensekeys td.valid_for.column-valid_for,
table.wp-list-table.lizenzschlssel td.valid_for.column-valid_for {
    vertical-align: middle;
    text-align: center;
}

table.wp-list-table.licensekeys td.status.column-status,
table.wp-list-table.lizenzschlssel td.status.column-status {
    vertical-align: middle;
    text-align: left;
}

table.wp-list-table.licensekeys span.lmfwc-date,
table.wp-list-table.lizenzschlssel span.lmfwc-date {
    display: inline-block;
    min-width: 100px;
    text-align: center;
}

/** License Key Placeholder */
.lmfwc-placeholder {
    display: inline-block;
    font-family: Consolas, monospace;
    font-weight: 400;
    min-width: 150px;
    min-height: 20px;
    text-align: center;
    position: relative;
    line-height: 20px;
    padding: 3px 10px 2px;
    margin-left: 25px;
    border-top-right-radius: 3px;
    border-bottom-right-radius: 3px;
    cursor: pointer;
}

.lmfwc-placeholder:hover {
    background-image: linear-gradient(to right, #c0c0c0, #8c8c8c);
    color: #ffffff;
}

.lmfwc-placeholder:before {
    font-family: 'dashicons', sans-serif;
    content: "\f112";
    position: absolute;
    top: 0;
    bottom: 0;
    left: -25px;
    width: 25px;
    background-color: #c0c0c0;
    color: #ffffff;
    line-height: 25px;
    border-top-left-radius: 3px;
    border-bottom-left-radius: 3px;
}

.lmfwc-placeholder.empty:after {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    content: 'XXXX-XXXX-XXXX-XXXX';
    color: rgba(0, 0, 0, .4);
    line-height: 25px;
}

.lmfwc-placeholder.empty:hover:after {
    color: #ffffff;
}

.lmfwc-spinner {
    opacity: 0;
    margin-left: 5px;
}

.lmfwc-clipboard {
    font-family: Consolas, monospace;
    background-color: #f0f0f0;
    color: #334;
    padding: 7px 14px;
    border: 1px solid rgba(0, 0, 0, .1);
    border-radius: 3px;
    opacity: 1;
    -webkit-box-shadow: 2px 3px 5px rgba(0, 0, 0, .1);
    box-shadow: 2px 3px 5px rgba(0, 0, 0, .1);
    -webkit-transition: all .5s ease-out;
    -o-transition: all .5s ease-out;
    transition: all .5s ease-out;
}

/* Source Icons */
.lmfwc-source-icon {
    max-width: 24px;
    max-height: 24px;
}

/* Custom status */
.lmfwc-status {
    padding: 3px 6px;
    position: relative;
    font-weight: 600;
    border-radius: 3px;
    cursor: default;
    border: 2px solid transparent;
    color: #6f6f6f;
    min-width: 90px;
}

.lmfwc-status.sold {
    border: 2px solid var(--color-info);
    color: var(--color-info);
}

.lmfwc-status.sold>span.dashicons {
    color: var(--color-info);
}

.lmfwc-status.delivered {
    border: 2px solid var(--color-success);
    color: var(--color-success);
}

.lmfwc-status.delivered>span.dashicons {
    color: var(--color-success);
}

.lmfwc-status.active {
    border: 2px solid var(--color-primary);
    color: var(--color-primary);
}

.lmfwc-status.active>span.dashicons {
    color: var(--color-primary);
}

.lmfwc-status.inactive {
    border: 2px solid var(--color-grey-1);
    color: var(--color-grey-1);
}

.lmfwc-status.inactive>span.dashicons {
    color: var(--color-grey-1);
}

.lmfwc-status.expired {
    border: 2px solid var(--color-danger);
    color: var(--color-danger);
}

.lmfwc-status.expired>span.dashicons {
    color: var(--color-danger);
}

.lmfwc-status.activation.done,
.lmfwc-status.activation.done>span.dashicons {
    color: var(--color-info);
}

/** My Account **/
.lmfwc-myaccount-license-key {
    font-family: Consolas, monospace;
    font-size: 13px;
}

/** Custom icons **/
.lmfwc-icons {
    width: 20px;
    height: 20px;
    display: inline-block;
}

.lmfwc-icons:before {
    font-family: woocommerce;
    text-align: center;
    display: inline-block;
    width: 100%;
    position: relative;
    top: 1px;
}

.lmfwc-icons.delivered:before {
    content: "\e01a";
}

/** Badges **/
.lmfwc-badge {
    display: inline-block;
    border-radius: 50%;
    width: 15px;
    height: 15px;
    line-height: 15px;
    text-align: center;
    padding: 2px;
    margin-left: .5em;
    cursor: default;
}

.lmfwc-badge.info {
    background-color: var(--color-info);
    color: #ffffff;
}

/** Licenses page dropdown width fix **/
.wrap.lmfwc #filter-by-order-id+.select2-container,
.wrap.lmfwc #filter-by-user-id+.select2-container,
.wrap.lmfwc #filter-by-license-id+.select2-container,
.wrap.lmfwc #filter-by-source+.select2-container,
.wrap.lmfwc #filter-by-product-id+.select2-container {
    width: auto !important;
    max-width: 10rem;
}

.lmfwc-status-delivered {
    border-color: var(--color-success);
    color: var(--color-success);
}

.lmfwc-status-delivered>span.dashicons {
    color: var(--color-success);
}

lmfwc-status-active {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

.lmfwc-status-active>span.dashicons {
    color: var(--color-primary);
}

.lmfwc-status-inactive {
    border-color: var(--color-inactive);
    color: var(--color-inactive);
}

.lmfwc-status-inactive>span.dashicons {
    color: #8f8f8f;
}

.lmfwc-field-placeholder {
    width: 100px;
    height: auto !important;
}


.lmfwc-tool-form-row {
    width: 100%;
    margin-bottom: 10px;
}

.lmfwc-tool-form-row label span,
.lmfwc-tool-form-row label small {
    font-weight: normal;
}

.lmfwc-tool-form-row label {
    display: block;
    font-weight: bold;
    margin-bottom: 5px;
}

.lmfwc-tool-progress-info,
.lmfwc-tool-progress-bar,
.lmfwc-tool-form-row #identifier {
    max-width: 400px;
    width: 100%;
}

.lmfwc-tool-progress-bar {
    position: relative;
    height: 20px;
    border: 1px solid #cccccc;
}

.lmfwc-tool-progress-bar-inner {
    position: absolute;
    left: 0;
    top: 0;
    margin-top: 0px !important;
    background-color: #73d95b;
    height: 100%;
    font-size: 0px;
    transition: width 600ms linear;
}

.lmfwc-tool-progress-info {
    text-align: center;
    font-size: 12px;
}

.lmfwc-tool-row>.lmfwc-tool-form .lmfwc-tool-form-row:last-child {
    margin-top: 15px;
    margin-bottom: 15px;
}

.lmfwc-tool-row>h3,
.lmfwc-tool-row>p,
.lmfwc-tool-row>.lmfwc-tool-form {
    padding-left: 20px;
    padding-right: 20px;
}

.lmfwc-tool-row {
    border: 1px solid #ccc;
    margin-bottom: 17px;
}

.lmfwc-small-badge {
    font-size: 12px;
    background: #f0f0f0;
    display: inline-block;
    border-radius: 4px;
    padding: 2px 5px !important;
    margin-left: 2px;
    line-height: 1;
}

.lmfwc-small-badge-success {
    background-color: #36be6c;
    color: #fff;
}

.lmfwc-application-download-button-form {
    display: inline;
}

.lmfwc-application-meta {
    list-style: none;
    padding: 0 !important;
    list-style-type: none !important;
    margin-left: 0;
}

.lmfwc-application-meta li {
    display: block;
    width: 100%;
    margin-bottom: 5px;
}

.lmfwc-application-meta li>span {
    font-weight: bold;
    display: inline-block;
}

.lmfwc-slide {
    display: inline-block;
    width: 31%;
    margin-right: 16px;
}

.lmfwc-slide-main {
    display: block;
    width: 100%;
}

.lmfwc-slide img {
    width: 220px;
    height: 120px;
    object-fit: scale-down;
}

.lmfwc-slide-controls ul {
    list-style: none;
    width: 100%;
    display: block;
    text-align: center;
}

.lmfwc-slide-controls ul li {
    display: inline-block;
}

.flex-direction-nav {
    display: none;
}

.lmfwc-txt-copied-to-clipboard {
    display: none;
}

input[type=checkbox].lmfwc-input-toggle::before {
    content: "" !important;
    display: block !important;
    width: 16px !important;
    height: 16px !important;
    background: #fff;
    position: absolute;
    top: 0;
    left: 0;
    border-radius: 100%;
    margin: 0px !important;
    -webkit-transition: all 0.2s ease-in-out;
    -moz-transition: all 0.2s ease-in-out;
    -o-transition: all 0.2s ease-in-out;
    transition: all 0.2s ease-in-out;
}

input[type=checkbox].lmfwc-input-toggle {
    border-color: #999 !important;
    background-color: #999 !important;
}

input[type=checkbox].lmfwc-input-toggle {
    -webkit-appearance: none;
    appearance: none;
    cursor: pointer;
    display: block !important;
    margin-bottom: 4px;
    height: 20px !important;
    width: 40px !important;
    border: 2px solid #935687;
    background-color: #935687;
    display: inline-block;
    text-indent: -9999px;
    border-radius: 10em;
    position: relative;
    margin-top: -1px;
    vertical-align: text-top;
    -webkit-transition: all 0.2s ease-in-out;
    -moz-transition: all 0.2s ease-in-out;
    -o-transition: all 0.2s ease-in-out;
    transition: all 0.2s ease-in-out;
}

input[type=checkbox].lmfwc-input-toggle:checked::before {
    left: 20px;
}

input[type=checkbox].lmfwc-input-toggle:checked {
    border-color: #935687 !important;
    background-color: #935687 !important;
}

/* Tuning Recharts */
.recharts-yAxis.yAxis line {
    stroke: transparent;
}

.recharts-yAxis .recharts-cartesian-axis-tick-line {
    visibility: hidden;
}

.recharts-tooltip-wrapper .d3-chart__tooltip {
    visibility: visible !important;
    left: 24px;
    top: 24px;
}

.recharts-cartesian-axis text tspan {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    font-size: 10px;
}

.recharts-cartesian-grid-horizontal line {
    stroke: #e2e4e7;
    stroke-width: 1;
    shape-rendering: crispEdges;
}

.licensechart-chart {
    margin-top: -16px;
    margin-bottom: 24px;
    background: #fff;
    border: 1px solid #ccd0d4;
    border-top: 0;
}

.licensechart-chart .licensechart-chart__header {
    min-height: 50px;
    border-bottom: 1px solid #ccd0d4;
    display: flex;
    flex-flow: row wrap;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.licensechart-chart .licensechart-chart__header .licensechart-chart__title {
    height: 18px;
    color: #24292d;
    font-size: 15px;
    font-weight: 600;
    line-height: 18px;
    margin-left: 16px;
    margin-right: 16px;
}

.licensechart-chart .licensechart-chart__body {
    display: flex;
    flex-direction: row;
    justify-content: flex-start;
    align-items: flex-start;
    width: 100%;
}

.licensechart-chart .licensechart-chart__body.licensechart-chart__body-column {
    flex-direction: column;
    margin-top: 16px;
}

.table_top_licenses h2 {
    font-size: 15px;
    font-weight: 600;
}

.table_top_licenses .woocommerce-pagination {
    display: none;
}

#license-manager-for-woocommerce .woocommerce-summary__item .woocommerce-summary__item-delta {
    display: none;
}

.woocommerce-placeholder-shimmer {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: 4px;
}

@keyframes shimmer {
    0% {
        background-position: -200% 0;
    }

    100% {
        background-position: 200% 0;
    }
}

.licensechart-chart__body .d3-chart__tooltip {

    position: relative !important;

}

#license-manager-for-woocommerce .woocommerce-filters-date__content-controls .woocommerce-filters-date__text,
#license-manager-for-woocommerce .woocommerce-dropdown-button__labels span:nth-child(2),
#license-manager-for-woocommerce .woocommerce-filters-date__content-controls .woocommerce-segmented-selection {
    display: none
}

.wrap.lmfwc {
    padding-left: 30px !important;
}

.lmfwc-dashboard-trends-card,
.lmfwc-dashboard-products-card,
.lmfwc-dashboard-activity-card,
.lmfwc-dashboard-recent-card {
    width: 100%;
}

/* Dashboard Revamp Custom Styles - Removed redundant overrides to allow Grid system control */


.lmfwc-bulk-checkbox input {
    margin: 12px 12px;
}

/* AppSumo Integration UI (Tabs & Integration Box) */
.lmfwc-appsumo-integration-box {
    background: #f6f7f7;
    padding: 20px;
    border-left: 4px solid #935687;
    border-radius: 4px;
    margin-bottom: 25px;
}

.lmfwc-appsumo-integration-box p {
    margin-top: 0 !important;
    font-size: 13px;
    color: #50575e;
}

.lmfwc-appsumo-integration-box ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 15px 0 0 !important;
}

.lmfwc-appsumo-integration-box li {
    margin-bottom: 12px !important;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
}

.lmfwc-appsumo-integration-box code {
    background: #fff;
    padding: 4px 8px;
    border: 1px solid #dcdcde;
    border-radius: 4px;
    font-family: Consolas, monospace;
    font-size: 12px;
    color: #2c3338;
    margin: 0 8px;
    word-break: break-all;
}

/* AppSumo Horizontal Tabs */
.lmfwc-appsumo-tabs-nav {
    display: flex;
    border-bottom: 1px solid #dcdcde;
    margin-bottom: 30px;
    gap: 30px;
}

.lmfwc-appsumo-tab-item {
    padding: 12px 5px;
    font-size: 14px;
    font-weight: 600;
    color: #646970;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.2s ease;
    user-select: none;
}

.lmfwc-appsumo-tab-item:hover {
    color: #935687;
}

.lmfwc-appsumo-tab-item.active {
    color: #2271b1;
    border-bottom-color: #2271b1;
}

/* Tab Panel Logic */
.lmfwc-appsumo-tab-panel {
    display: none;
    overflow: visible !important;
}

.lmfwc-appsumo-tab-panel.active {
    display: block;
    overflow: visible !important;
    animation: lmfwcFadeIn 0.3s ease;
}

@keyframes lmfwcFadeIn {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Copy Button Refinement */
.lmfwc-copy-url {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    background: #fff;
    border: 1px solid #dcdcde;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #935687;
    position: relative;
    margin-top: 2px;
}

.lmfwc-copy-url:hover {
    background: #935687;
    color: #fff;
    border-color: #935687;
}

.lmfwc-copy-feedback {
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%) translateY(-8px);
    background: #32373c;
    color: #fff;
    font-size: 11px;
    padding: 4px 10px;
    border-radius: 4px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s ease;
    z-index: 100;
}

.lmfwc-copy-feedback.show {
    opacity: 1;
    transform: translateX(-50%) translateY(-12px);
}

/* AppSumo Global Header Styles */
.lmfwc-appsumo-global-header {
    margin-bottom: 25px;
    padding-bottom: 15px;
}

.lmfwc-appsumo-global-header h2 {}

.lmfwc-appsumo-global-header p {
    font-size: 14px;
    color: #181818;
    margin: 0 !important;
    font-weight: 500;
}
/* Product Mapping Selection Styles */
.lmfwc-appsumo-product-select-wrapper {
    margin-bottom: 20px;
    position: relative;
}

.lmfwc-appsumo-product-select-wrapper .select2-container {
    max-width: 400px;
    width: 100% !important;
}

/* Select2 overrides for better dashboard integration */
.select2-container--default .select2-selection--single {
    height: 30px !important;
    border-color: #8c8f94 !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 28px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 28px !important;
}

/* Ensure Select2 dropdown is above everything */
.select2-container--default .select2-dropdown {
    z-index: 999999 !important;
    border-color: #8c8f94 !important;
    box-shadow: 0 4px 10px rgba(0,0,0,0.15) !important;
}

/* AppSumo Activation Page Styles */
.lmfwc-appsumo-activation-card {
    max-width: 500px;
    margin: 40px auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    overflow: hidden;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen-Sans, Ubuntu, Cantarell, 'Helvetica Neue', sans-serif;
}

.lmfwc-appsumo-card-header {
    background: #f8f9fa;
    padding: 30px;
    text-align: center;
    border-bottom: 1px solid #edf2f7;
}

.lmfwc-appsumo-card-header h2 {
    margin: 0 0 10px 0 !important;
    color: #1a202c;
    font-size: 24px;
    font-weight: 700;
}

.lmfwc-appsumo-subtitle {
    color: #718096;
    font-size: 15px;
    margin: 0 !important;
    line-height: 1.5;
}

.lmfwc-appsumo-card-body {
    padding: 30px;
}

.lmfwc-appsumo-info-box {
    background: #ebf8ff;
    border-left: 4px solid #3182ce;
    padding: 15px;
    margin-bottom: 25px;
    border-radius: 4px;
}

.lmfwc-appsumo-info-box p {
    margin: 0 !important;
    color: #2c5282;
    font-size: 14px;
}

.lmfwc-warning-text {
    color: #c53030;
    margin-top: 5px !important;
}

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

.lmfwc-form-row {
    display: flex;
    gap: 20px;
}

.lmfwc-form-row .lmfwc-form-group {
    flex: 1;
}

.lmfwc-form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #4a5568;
    margin-bottom: 8px;
}

.lmfwc-input, .lmfwc-input-readonly {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 15px;
    transition: all 0.2s;
}

.lmfwc-input:focus {
    border-color: #3182ce;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.15);
    outline: none;
}

.lmfwc-input-readonly {
    background: #f7fafc;
    color: #a0aec0;
    cursor: default;
}

.lmfwc-appsumo-btn-primary {
    width: 100%;
    padding: 14px;
    background: #ff4d4d;
    color: #fff;
    border: none;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
}

.lmfwc-appsumo-btn-primary:hover {
    background: #e60000;
}

.lmfwc-form-footer {
    text-align: center;
    margin-top: 20px !important;
    font-size: 14px;
}

.lmfwc-form-footer a {
    color: #3182ce;
    text-decoration: none;
}

.lmfwc-form-footer a:hover {
    text-decoration: underline;
}

.lmfwc-appsumo-error {
    background: #fff5f5;
    color: #c53030;
    padding: 20px;
    border-radius: 8px;
    border: 1px solid #feb2b2;
    text-align: center;
}


/* Spin Animation */
.spin {
    animation: lmfwc-spin 2s infinite linear;
    display: inline-block;
}
@keyframes lmfwc-spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(359deg); }
}
.lmfwc-appsumo-processing {
    margin-top: 10px !important;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

