/* Admin Page Layout */
.sifency-templates-header { margin: 15px 0; }
.sifency-pro-badge { background-color: #ffba00; color: #000; font-size: 9px; padding: 2px 5px; border-radius: 3px; margin-left: 5px; font-weight: bold; vertical-align: middle; }

/* Conditions Builder */
.sifency-conditions-group { border: 1px solid var(--sifency-border-color); border-radius: 3px; margin-bottom: 20px; }
.sifency-conditions-group h3 { font-size: 14px; margin: 0; padding: 10px 15px; background: #f9f9f9; border-bottom: 1px solid var(--sifency-border-color); }
.sifency-conditions-list { padding: 15px; }
.sifency-conditions-group > button { margin: 0 15px 15px; }
.sifency-condition-row { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.sifency-condition-row select { min-width: 150px; }
.sifency-condition-row .sifency-condition-value { flex-grow: 1; }
.sifency-remove-condition { color: #a00; text-decoration: none; font-size: 18px; }
.sifency-condition-row .select2-container { flex-grow: 1; }
.d-flex{display: flex; gap: 5px;}

.sifency-couple-text-btn a{
    font-size: 14px;
}

.text_underline_animation::after,
.text-underline-animation::after {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  height: 1px;
  width: 100%;
  background-color: currentColor;
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.3s ease;
}
.text_underline_animation:hover::after,
.text-underline-animation:hover::after {
  transform: scaleX(1);
  transform-origin: right;
}
.live-link-btn{
    text-decoration: none;
    color: var(--sifency-accent);
    font-size: 16px;
}
.live-link-btn:hover{
    color: var(--sifency-accent);
}
.sifency-new-template-wrap .sifency-modal-body .sifency-form-group select {
    display: block;
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
}
.sifency-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100000;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: rgba(10, 22, 41, 0.7);
    -webkit-backdrop-filter: blur(5px);
    backdrop-filter: blur(5px);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.sifency-modal-overlay.is-visible {
    opacity: 1;
    visibility: visible;
}

/* 2. The Modal Container */
.sifency-modal-wrap {
    background: #ffffff;
    border-radius: 8px;
    width: 95%;
    max-width: 991px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    transform: scale(0);
    transition: transform 0.3s ease-out;
    max-height: 90vh;
}
.sifency-modal-overlay.is-visible .sifency-modal-wrap {
    transform: scale(1);
}
.sifency-modal-wrap .select2-container--default .select2-search--dropdown .select2-search__field{
    border: none !important;
    box-shadow: none !important;
}
.sifency-modal-wrap .select2-container--open .select2-dropdown--below{
    border: 1px solid var(--sifency-border-color) !important;
    border-radius: 15px !important;
}

/* 3. Header */
.sifency-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
    border-bottom: 1px solid var(--sifency-border-color);
    flex-shrink: 0;
}
.sifency-modal-header h2 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
    color: #111827;
}
.sifency-modal-close {
    background: #f3f4f6;
    border: none;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    color: #6b7280;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    transition: background-color 0.2s ease, color 0.2s ease;
}
.sifency-modal-close:hover {
    background-color: #e5e7eb;
    color: #111827;
}
/* 4. Body */
.sifency-modal-body {
    padding: 24px;
    overflow-y: auto;
    color: #374151;
}
/* Custom scrollbar for a polished look */
.sifency-modal-body::-webkit-scrollbar {
    width: 8px;
}
.sifency-modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
}
.sifency-modal-body::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}
.sifency-modal-body::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

/* 5. Footer */
.sifency-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--sifency-border-color);
    text-align: right;
    background-color: #f9fafb;
    border-bottom-left-radius: 8px;
    border-bottom-right-radius: 8px;
    flex-shrink: 0;
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}
button#sifency-create-and-save,
button#sifency-save-section-draft,
.sifency-secondary-btn{
    background-color: #f3f4f6;
    color: #101010;
    padding: 3px 16px;
    font-size: 14px;
    border-radius: 12px;
    border: none;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}
.button#sifency-create-and-save:hover,
.sifency-secondary-btn:hover{
    background-color: #e5e7eb;
}
.sifency-admin-accent-btn,
.button.button-primary.sifency-admin-accent-btn{
    background-color: var(--sifency-accent);
    border-color: var(--sifency-accent);
    color: #fff;
    padding: 3px 16px;
    font-size: 14px;
    border-radius: 12px;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}
.button.button-primary.sifency-admin-accent-btn,
.sifency-admin-accent-btn{
 background-color: var(--sifency-accent-hover);
    border-color: var(--sifency-accent-hover);
}
#sifency-save-conditions-btn {
    background-color: var(--sifency-accent);
    border-color: var(--sifency-accent);
    color: #fff;
    padding: 3px 16px;
    font-size: 14px;
    border-radius: 12px;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}
#sifency-save-conditions-btn:hover {
    background-color: var(--sifency-accent-hover);
    border-color: var(--sifency-accent-hover);
}
#sifency-save-conditions-btn.disabled,
#sifency-save-conditions-btn:disabled {
    background-color: #9ca3af;
    border-color: #9ca3af;
    cursor: not-allowed;
}
.sifency-modal-footer .spinner {
    float: none;
    vertical-align: middle;
    margin: -2px 5px 0 0;
    visibility: hidden;
    display: none;
}
.sifency-modal-footer .spinner.is-active {
    visibility: visible;
}

/* Toggle Switch */
.sifency-switch { position: relative; display: inline-block; width: 44px; height: 24px; vertical-align: middle; }
.sifency-switch input { opacity: 0; width: 0; height: 0; }
.sifency-switch .slider { position: absolute; cursor: pointer; top: 0; left: 0; right: 0; bottom: 0; background-color: #ccc; transition: .4s; }
.sifency-switch .slider:before { position: absolute; content: ""; height: 16px; width: 16px; left: 4px; bottom: 4px; background-color: white; transition: .4s; }
.sifency-switch input:checked + .slider { background-color: var(--sifency-accent); }
.sifency-switch input:checked + .slider:before { transform: translateX(20px); }
.sifency-switch .slider.round { border-radius: 34px; }
.sifency-switch .slider.round:before { border-radius: 50%; }
.status-label { vertical-align: middle; }

.sifency-switch { position: relative; display: inline-block; width: 44px; height: 24px; vertical-align: middle; }

.sifency-switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.sifency-templates-table td .sifency-switch {
    margin-right: 8px;
}

.sifency-status-label {
  position: relative;
  display: inline-flex;
  align-items: center;
  cursor: default;
  gap: 6px;
}

.sifency-status-label[data-tooltip]::after {
  content: '?';
  display: inline-flex;
  justify-content: center;
  align-items: center;
  width: 18px;
  height: 18px;
  background-color: #a00;
  color: #fff;
  border-radius: 50%;
  font-size: 12px;
  font-weight: bold;
  transition: background-color 0.3s;
}

/* Tooltip box (hidden by default) */
.sifency-status-label[data-tooltip]::before {
  content: attr(data-tooltip);
  position: absolute;
  bottom: 120%; /* Show above the label */
  left: 50%;
  transform: translateX(-50%);
  background-color: #fff;
  color: #101010;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 12px;
  line-height: 1.4;
  white-space: normal;
  word-wrap: break-word;
  width: max-content;
  max-width: 220px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
  z-index: 1000;
}

/* Tooltip arrow */
.sifency-status-label[data-tooltip]::before::after {
  content: '';
  position: absolute;
  top: 100%; /* Arrow below the tooltip box */
  left: 50%;
  transform: translateX(-50%);
  border-width: 6px;
  border-style: solid;
  border-color: #f3f3f3 transparent transparent transparent;
}

/* Show tooltip on hover */
.sifency-status-label[data-tooltip]:hover::before {
  opacity: 1;
  transform: translateX(-50%) translateY(-4px);
}
.sifency-edit-elementor-link,
.sifency-preview-link{
    font-size: 14px;
}
.sifency-separator{
    color: #ececec;

}
.sifency-templates-header {
    margin: 15px 0;
}
.sifency-pro-badge {
    background-color: #ffba00;
    color: #000;
    font-size: 9px;
    padding: 2px 5px;
    border-radius: 3px;
    margin-left: 5px;
    font-weight: bold;
    vertical-align: middle;
}
.sifency-conditions-group {
    border: 1px solid var(--sifency-border-color);
    border-radius: 6px;
    margin-bottom: 24px;
    background: #fff;
}
.sifency-conditions-group h3 {
    font-size: 0.9rem;
    font-weight: 600;
    margin: 0;
    padding: 12px 16px;
    background: #f9fafb;
    border-bottom: 1px solid var(--sifency-border-color);
    color: #111827;
    border-top-left-radius: 6px;
    border-top-right-radius: 6px;
}
.sifency-conditions-list {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.sifency-no-rules-message {
    color: #6b7280;
    margin: 0;
}
.sifency-add-condition {
    margin: 0 16px 16px;
    border-radius: 6px !important;
}

.sifency-condition-row {
    display: grid;
    grid-template-columns: repeat(2, minmax(150px, 1fr)) 2fr auto;
    gap: 12px;
    align-items: center;
}
.sifency-condition-row select {
    width: 100%;
    padding: 8px 12px;
    border-radius: 6px;
    border: 1px solid var(--sifency-border-color);
    background-color: #fff;
    font-size: 14px;
    color: #374151;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3e%3cpath stroke='%236b7280' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='M6 8l4 4 4-4'/%3e%3c/svg%3e");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.5em 1.5em;
    padding-right: 2.5rem;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.sifency-condition-row select:focus {
    border-color: var(--sifency-accent) !important;
    box-shadow: none !important;
    outline: none !important;
}

.sifency-condition-row .select2-container .select2-selection--single {
    height: 38px;
    border-radius: 6px;
    border: 1px solid var(--sifency-border-color);
    box-shadow: none !important;
}
.sifency-condition-row .select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 36px;
    padding-left: 12px;
}
.sifency-condition-row .select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 36px;
}
.sifency-remove-condition {
    color: #9ca3af;
    text-decoration: none;
    font-size: 18px;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: color 0.2s ease, background-color 0.2s ease;
}
.sifency-remove-condition:hover {
    color: #ef4444;
    background-color: #fee2e2;
}

button.button.sifency-add-condition{
    margin: 20px;
}

.sifency-admin-primary-btn,
.sifency-templates-list-container .page-title-action {
    background-color: var(--sifency-accent);
    color: #fff;
    padding: 8px 20px;
    border-radius: 15px;
    text-decoration: none;
    transition: all 0.2s ease-in-out;
    border-radius: 5px;
    border: none;
    cursor: pointer;
}
.sifency-templates-list-container .page-title-action:hover {
    background-color: var(--sifency-accent-hover);
    border-color: var(--sifency-accent-hover);
    transform: translateY(-1px);
    color: #fff;
}

/* 2. The Main Table Container */
.sifency-templates-list-container .sifency-templates-table {
    border: none;
    border-radius: 8px;
    border-collapse: separate; /* Important for border-radius */
    border-spacing: 0;
    overflow: hidden;
    border: 1px solid var(--sifency-border-color);
}

/* 3. Table Header */
.sifency-templates-table thead tr {
    background-color: var(--white-color);
}
.table-list-item-title{
    font-size: 16px;
    line-height: 26px;
}
.sifency-templates-table thead th {
    border-bottom: 1px solid var(--sifency-border-color);
    padding: 12px 20px;
    font-weight: 500;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    text-align: left;
}

.sifency-post-switch-status-col{
    width: 150px;
    max-width: 150px;
    min-width: 150px;

}
.sifency-post-action-col{
    width: 300px;
    max-width: 300px;
    min-width: 300px;

}
.sifency-post-condition-col{
    width: 200px;
    max-width: 200px;
    min-width: 2000px;

}

.sifency-post-publish-status-col {
    width: 100px;
    max-width: 100px;
    min-width: 100px;

}


/* 4. Table Body and Rows */
.sifency-templates-table tbody tr {
    background-color: #fff;
    transition: background-color 0.2s ease-in-out;
}
.sifency-templates-table tbody tr:hover {
    background-color: #f9fafb;
}
.sifency-templates-table tbody tr:nth-child(odd) {
    background-color: #fdfdfd;
}
.sifency-templates-table tbody tr:nth-child(odd):hover {
    background-color: #f7f7f8;
}
.sifency-post-publish-status-col{
    max-width: 100px;
}
.sifency-templates-table tbody td {
    padding: 20px;
    border-bottom: 1px solid #f0f1f1;
    vertical-align: middle;
    color: #374151;
    min-height: 50px;
}
.sifency-templates-table tbody tr:last-child td {
    border-bottom: none;
}


.sifency-templates-table td strong a {
    font-weight: 600;
    color: #111827;
    text-decoration: none;
    transition: color 0.2s ease;
}
.sifency-templates-table td strong a:hover {
    color: var(--sifency-accent);
}

.sifency-templates-table .sifency-conditions-summary {
    color: #6b7280;
    font-size: 13px;
}

.sifency-templates-table td:last-child {
    display: flex;
    align-items: center;
    gap: 8px;
}
.sifency-templates-table .button.sifency-edit-conditions-btn {
    background: #fff;
    border: 1px solid #d1d5db;
    color: #374151;
    border-radius: 6px;
    transition: all 0.2s ease-in-out;
}
.sifency-templates-table .button.sifency-edit-conditions-btn:hover {
    background: #f9fafb;
    border-color: #9ca3af;
    color: #111827;
}
.sifency-templates-table .button-link-delete {
    color: #6b7280;
    transition: color 0.2s ease-in-out;
}
.sifency-templates-table .button-link-delete:hover {
    color: #ef4444; /* A modern, less harsh red */
    background-color: transparent;
}


/* 6. "No Templates Found" State */
.sifency-templates-table tbody tr:only-child td {
    padding: 20px;
    font-size: 15px;
}
.sifency-nav-item.is-active .sifency-pro-badge::after {
    content: "PRO";
    position: fixed;
    top: 50vh;
    left: 32vw;
    transform: translate(-50%, -50%);
    font-size: 18vw;
    color: #facc15;
    font-weight: 900;
    pointer-events: none;
    white-space: nowrap;
    animation: proFadeIn 0.5s forwards;
    
}

@keyframes proFadeIn {
    from { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
    to   { opacity: 0.1; transform: translate(-50%, -50%) scale(1); }
}
.sifency-premium-upsell-card {
    background: #fff;
    border: 1px solid var(--sifency-border-color);
    border-radius: 8px;
    padding: 40px;
    max-width: 550px;
}

.sifency-upsell-icon {
    display: inline-block;
    background-color: #eef4ff; /* A light, friendly blue */
    border-radius: 50%;
    padding: 12px;
    margin-bottom: 20px;
    line-height: 0;
}

.sifency-upsell-icon svg path {
    fill: var(--sifency-accent); /* WordPress admin blue */
}

.sifency-premium-upsell-card h2 {
    font-size: 20px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 12px;
}

.sifency-premium-upsell-card p {
    font-size: 15px;
    color: #6b7280;
    line-height: 1.6;
    max-width: 450px;
}
.sifency-beta-badge {
    background-color: #facc15;
    color: #111827;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 6px;
    margin-left: 6px;
    text-transform: uppercase;
    transition: all 0.2s ease;
}

.sifency-nav-item.is-active .sifency-beta-badge {
    background-color: rgba(255,255,255,0.3);
    color: #fff;
}
/* Modern Beta Badge / Overlay for Active Tab */
.sifency-nav-item .sifency-beta-badge {
    position: relative;
    display: inline-block;
    background-color: #facc15; /* bright yellow */
    color: #111827;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 6px;
    margin-left: 6px;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

/* Active Tab: Large semi-transparent Beta text overlay */
.sifency-nav-item.is-active .sifency-beta-badge::after {
    content: "BETA";
    position: fixed;
    top: 80vh;
    left: 39vw;
    transform: translate(-50%, -50%);
    font-size: 20vw; 
    color: #facc15; 
    font-weight: 900;
    pointer-events: none;
    white-space: nowrap;
    opacity: 0;
    animation: betaFadeIn 0.5s forwards;
}

/* Smooth fade-in animation */
@keyframes betaFadeIn {
    from { opacity: 0; transform: translate(-50%, -50%) scale(0.8); }
    to   { opacity: 0.1; transform: translate(-50%, -50%) scale(1); }
}

/* Optional: fade out when inactive */
.sifency-nav-item:not(.is-active) .sifency-beta-badge::after {
    opacity: 0;
    transition: opacity 0.5s ease;
}

.sifency-upgrade-button {
    display: inline-block;
    background-color: #22c55e;
    color: #fff;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    transition: all 0.2s ease-in-out;
}

.sifency-upgrade-button:hover {
    background-color: #16a34a;
    transform: translateY(-2px);
    color: #fff;
}

.sifency-upgrade-button:focus {
    box-shadow: 0 0 0 2px #fff, 0 0 0 4px #22c55e;
}
/* Modern tooltip wrapper */
.sifency-nav-item[title] {
    position: relative;
    cursor: pointer;
}

/* Tooltip box */
.sifency-nav-item[title]:hover::after {
    content: attr(title);
    position: absolute;
    left: 100%;
    transform: translateY(-80%) scale(0.95);
    background: var(--sifency-accent);
    color: #fff;
    padding: 20px 15px;
    border-radius: 10px;
    font-size: 14px;
    display: inline-block;
    width: max-content;
    height: auto;
    white-space: normal;
    overflow-wrap: break-word;
    word-break: break-word;

    box-shadow: 0 12px 28px rgba(0,0,0,.25);
    opacity: 0;
    pointer-events: none;
    transition: transform .25s ease, opacity .25s ease;
    z-index: 99999;
}

/* Tooltip arrow */
.sifency-nav-item[title]:hover::before {
    content: "";
    position: absolute;
    left: 100%;
    transform: translateY(-80%);
    border-style: solid;
    border-width: 2px;
    border-color: transparent var(--sifency-accent) transparent transparent;
    opacity: 0;
    transition: opacity .25s ease;
}

/* Show tooltip */
.sifency-nav-item[title]:hover::after,
.sifency-nav-item[title]:hover::before {
    opacity: 1;
    transform: translateY(-50%) scale(1);
}

/* Responsive for small screens */
@media (max-width: 600px) {
    .sifency-nav-item[title]:hover::after {
        left: auto;
        right: 110%;
        max-width: 220px;
    }
    .sifency-nav-item[title]:hover::before {
        left: auto;
        right: 104%;
        border-color: transparent transparent transparent var(--sifency-accent);
    }
}

/* ===========================================
   Dashboard Layout
   =========================================== */
.sifency-dashboard-layout {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

/* ===========================================
   Left Sidebar Navigation
   =========================================== */
.sifency-dashboard-nav {
    flex-shrink: 0;
    width: 220px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(8px);
    border: 1px solid var(--sifency-border-color);
    border-radius: 12px;
    padding: 12px;
    transition: all 0.3s ease;
}

.sifency-nav-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    border-radius: 8px;
    text-decoration: none;
    color: #374151;
    font-weight: 500;
    gap: 8px;
    transition: all 0.3s ease;
    background-color: transparent;
    position: relative;
    border: none;
}

.sifency-nav-item:hover {
    background-color: rgba(0,0,0,0.03);
    color: var(--sifency-accent);
}

.sifency-nav-item.is-active {
    background: var(--sifency-accent);
    color: #fff;
}

.sifency-nav-item.is-active:hover {
    background-color: var(--sifency-accent-hover);
}

/* ===========================================
   Icon Styling
   =========================================== */
.sifency-nav-item-icon {
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    min-width: 18px; /* keep icons aligned */
}

/* Label styling */
.sifency-nav-item-label {
    flex-grow: 1;
}

/* ===========================================
   PRO Badge
   =========================================== */
.sifency-pro-badge {
    background-color: #eef4ff;
    color: #2563eb;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 6px;
    margin-left: auto;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

.sifency-nav-item.is-active .sifency-pro-badge {
    background-color: rgba(255,255,255,0.3);
    color: #fff;
}

/* ===========================================
   Main Content Area
   =========================================== */
.sifency-dashboard-content {
    flex-grow: 1;
    min-width: 0;
    margin-right: 20px;
}

/* ===========================================
   Scrollbar (Optional Modern Look)
   =========================================== */
.sifency-dashboard-nav::-webkit-scrollbar {
    width: 6px;
}

.sifency-dashboard-nav::-webkit-scrollbar-track {
    background: transparent;
}

.sifency-dashboard-nav::-webkit-scrollbar-thumb {
    background-color: rgba(0,0,0,0.1);
    border-radius: 10px;
}

.sifency-dashboard-nav::-webkit-scrollbar-thumb:hover {
    background-color: rgba(0,0,0,0.2);
}

/* ==========================================================================
   New Template Modal Styles
   ========================================================================== */
.sifency-new-template-wrap {
    width: 800px;
}
.sifency-new-template-wrap  .sifency-modal-body{
   padding: 150px;
}
.sifency-new-template-wrap  .sifency-modal-body .sifency-form-group select{
   min-width: 100%;
}
.sifency-new-template-wrap  .sifency-modal-body .sifency-form-group select option[selected]{
   background: var(--sifency-accent);
   color: var(--white-color);
}
.sifency-new-template-wrap  .sifency-modal-body .sifency-form-group select option:hover{
   background: var(--sifency-accent);
   color: var(--white-color);
}
.sifency-new-template-wrap  .sifency-modal-body .sifency-form-group select::-internal-select-autofill-preview[popover]{
   box-shadow: none !important;
   border: none !important;
}

.sifency-form-group {
    margin-bottom: 20px;
}
.sifency-form-group:last-of-type {
    margin-bottom: 0;
}
.sifency-form-group label {
    display: block;
    font-weight: 600;
    color: #111827;
    margin-bottom: 8px;
}
.sifency-form-group select,
.sifency-form-group input[type="text"] {
    width: 100%;
    padding: 5px 10px;
    border-radius: 6px;
    border: 1px solid var(--sifency-border-color);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    box-shadow: none;
}
.sifency-form-group select:focus,
.sifency-form-group input[type="text"]:focus {
    border-color: var(--sifency-accent);
    outline: none;
    box-shadow: none;
}

.sifency-condition-badges {
	display: flex;
	gap: 8px;
	align-items: center;
}

.sifency-badge {
	display: inline-flex;
	align-items: center;
	padding: 3px 8px;
	border-radius: 6px;
	font-size: 13px;
	font-weight: 500;
}
.button.sifency-add-condition.include:hover,
.sifency-badge.include {
	background: #e6f9ed;
	color: #1a7f37;
	border: 1px solid #b6efc8;
}
.button.sifency-add-condition.exclude:hover,
.sifency-badge.exclude {
	background: #fde8e8;
	color: #b91c1c;
	border: 1px solid #f5c2c2;
}

.sifency-badge .dashicons {
	font-size: 15px;
	margin-right: 0px;
	position: relative;
	top: 3px;
}

.sifency-notset {
	color: #888;
	font-style: italic;
}

/* --- Modern Admin Buttons --- */
.sifency-action-buttons {
	display: flex;
	gap: 8px;
	align-items: center;
}

.sifency-btn {
	display: inline-flex;
	align-items: center;
	gap: 3px;
	padding: 6px 12px;
	font-size: 13px;
	font-weight: 500;
	border: 1px solid transparent;
	border-radius: 6px;
	text-decoration: none;
	cursor: pointer;
	transition: all 0.2s ease;
}

.sifency-btn .dashicons {
	font-size: 16px;
	margin-top: 5px;
}

/* --- Variants --- */
.sifency-btn.edit {
	background: #e8f4ff;
	color: #007cba;
	border-color: #b3d8ff;
}

.sifency-btn.edit:hover {
	background: var(--sifency-accent-hover);
	color: #fff;
    border-color: var(--sifency-accent-hover);
}

.sifency-btn.delete {
	background: #fdeaea;
	color: #c0392b;
	border-color: #f5c2c2;
}

.sifency-btn.delete:hover {
	background: #c0392b;
	color: #fff;
}

.sifency-btn.restore {
	background: #ecfdf5;
	color: #047857;
	border-color: #a7f3d0;
}

.sifency-btn.restore:hover {
	background: #047857;
	color: #fff;
}

.sifency-btn.delete-perm {
	background: #fef2f2;
	color: #b91c1c;
	border-color: #fecaca;
}

.sifency-btn.delete-perm:hover {
	background: #b91c1c;
	color: #fff;
}


/* ========================================================================== */
/* 🌟 Sifency Admin Topbar
/* ========================================================================== */

.sifency-admin-page .wrap {
    margin-top: 0;
}

.sifency-admin-topbar {
    position: sticky;
    top: 0;
    z-index: 98;
    background: #ffffff;
    border: 1px solid var(--sifency-border-color);
    padding: 0 24px;
    margin: 0 0 25px 0;
    backdrop-filter: blur(8px);
    transition: all 0.2s ease-in-out;
    margin-left: -20px;
    margin-bottom: 20px;
}

/* Inner Flex Wrapper */
.sifency-topbar-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 24px;
}

/* -------------------------------------------------------------------------- */
/* LEFT SECTION: Brand + Logo */
/* -------------------------------------------------------------------------- */
.sifency-topbar-left {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 0;
    padding-right: 30px;
    border-right: 1px solid var(--sifency-border-color);
    padding-bottom: 20px;
}
.sifency-topbar-logo {
    height: 36px;
    width: auto;
    border-radius: 8px;
}

.sifency-topbar-brand {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.brand-name {
    font-size: 17px;
    font-weight: 700;
    color: #1d2327;
    letter-spacing: -0.2px;
}

.brand-version {
    font-size: 11px;
    color: #5c6066;
    background: #f3f4f6;
    padding: 3px 7px;
    border-radius: 4px;
    display: inline-block;
    line-height: 1;
}

/* -------------------------------------------------------------------------- */
/* RIGHT SECTION: Info + Upgrade */
/* -------------------------------------------------------------------------- */

.sifency-topbar-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 5px;
    padding-bottom: 10px;
}

.sifency-topbar-info {
    display: flex;
    align-items: center;
    gap: 20px;
    font-size: 13px;
    padding: 10px 0 6px 0;
}

.sifency-info-link {
    text-decoration: none;
    color: #555c63;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.15s ease-in-out;
}
.sifency-info-link:hover {
    color: #007cba;
    transform: translateY(-1px);
}

/* CTA Button */
.sifency-upgrade-btn {
    background: linear-gradient(90deg, #ffb900, #ff9e00);
    color: #1d2327;
    font-weight: 600;
    text-decoration: none;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: 13px;
    transition: all 0.15s ease-in-out;
    box-shadow: 0 2px 6px rgba(255, 185, 0, 0.25);
}
.sifency-upgrade-btn:hover {
    background: linear-gradient(90deg, #ffc83a, #ffad1d);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(255, 185, 0, 0.35);
}

/* -------------------------------------------------------------------------- */
/* NAV MENU BAR */
/* -------------------------------------------------------------------------- */

.sifency-topbar-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    border-top: 1px solid var(--sifency-border-color);
    padding: 10px 0 0;
    width: 100%;
    flex-wrap: wrap;
}

.sifency-topbar-menu .menu-item {
    position: relative;
    font-size: 14px;
    font-weight: 500;
    color: #444c54;
    text-decoration: none;
    padding: 8px 12px;
    border-radius: 6px;
    transition: all 0.15s ease;
}
.sifency-topbar-menu .menu-item:hover {
    background: #f6f8fa;
    color: #007cba;
}
.sifency-topbar-menu .menu-item.is-active {
    background: #e9f5ff;
    color: #007cba;
    font-weight: 600;
}

/* -------------------------------------------------------------------------- */
/* RESPONSIVE */
/* -------------------------------------------------------------------------- */

@media screen and (max-width: 1100px) {
    .sifency-topbar-inner {
        flex-direction: column;
        align-items: flex-start;
    }
    .sifency-topbar-right {
        align-items: flex-start;
        width: 100%;
    }
    .sifency-topbar-menu {
        gap: 6px;
    }
}

.sifency-templates-header{
    position: relative;
}
.sifency-floating-add-btn.text p.submit .button{
    padding: 0px;
    background: transparent;
    border: none;
    color: var(--white-color);
    box-shadow: none;
    outline: none;
}
.sifency-floating-add-btn.text p.submit{
    padding: 0px;
    margin: 0px;
}
.sifency-floating-add-btn {
    position: fixed;
    right: 30px;
    bottom: 30px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: var(--sifency-accent);
    border: none;
    padding: 12px 16px;
    border-radius: 100px !important;
    cursor: pointer;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(76, 110, 245, 0.35);
}

.sifency-floating-add-btn:hover {
    background: var(--sifency-accent);
    box-shadow: 0 6px 15px rgba(76, 110, 245, 0.45);
}

.sifency-add-icon {
    background: #fff;
    color: var(--sifency-accent);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    line-height: 110%;
    font-weight: bold;
    flex-shrink: 0;
    transition: transform 0.25s ease;
}

.sifency-floating-add-btn:hover .sifency-add-icon {
    transform: rotate(90deg) scale(1.1);
}

.sifency-add-label {
    max-width: 0;
    opacity: 0;
    white-space: nowrap;
    transition: all 0.35s ease;
}

/* Expand label on hover */
.sifency-floating-add-btn:hover .sifency-add-label {
    max-width: 300px;
    opacity: 1;
}
/* Floating Button */
.sifency-fullscreen-btn {
    position: fixed;
    top: 125px;
    right: 15px;
    z-index: 99;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    background: var(--sifency-accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 12px rgba(76, 110, 245, 0.35);
}

.sifency-fullscreen-btn:hover {
    background: var(--sifency-accent);
    box-shadow: 0 6px 15px rgba(76, 110, 245, 0.45);
}

/* Icons */
.icon-expand,
.icon-compress {
    position: fixed;
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.icon-compress {
    opacity: 0;
    transform: scale(0.6);
}

.fullwidth-enabled .icon-expand {
    opacity: 0;
    transform: scale(0.6);
}

.fullwidth-enabled .sifency-pricing-dashboard,
.fullwidth-enabled .sifency-theme-grid,
.fullwidth-enabled .sifency-admin-wrap,
.fullwidth-enabled .sifency-dashboard-content,
.fullwidth-enabled .sifency-admin-topbar
{
    margin-right: 0px;
}
.fullwidth-enabled .icon-compress {
    opacity: 1;
    transform: scale(1);
}

.fullwidth-enabled .sifency-page-wrapper,
.fullwidth-enabled .sifency-admin-wrapper,
.fullwidth-enabled .wrap,
.fullwidth-enabled .sifency-admin-container {
    max-width: 100% !important;
    width: 100vw !important;
    left: 0 !important;
    right: 0 !important;
    margin: 0 !important;
    min-height: 100vh;
    z-index: 999999999999999;
}
.fullwidth-enabled body,
.fullwidth-enabled html {
    overflow: hidden !important;
    height: 100vh !important;
}

.fullwidth-enabled .sifency-admin-topbar{
    margin-top: 0px;
}
.fullwidth-enabled .sifency-license-wrapper {
    
    margin-right: 0px !important;
}
.fullwidth-enabled #wpcontent{
    margin: 0px !important;
    padding: 0px !important;
}

.fullwidth-enabled #adminmenuwrap,
.fullwidth-enabled #adminmenuback,
.fullwidth-enabled #adminmenu {
    display: none !important;
}

.fullwidth-enabled #wpadminbar {
    display: none !important;
}

.fullwidth-enabled #wpfooter {
    display: none !important;
}

.fullwidth-enabled .notice,
.fullwidth-enabled div.updated,
.fullwidth-enabled div.error,
.fullwidth-enabled .update-nag {
    display: none !important;
}

.fullwidth-enabled #screen-meta,
.fullwidth-enabled #screen-meta-links {
    display: none !important;
}

.fullwidth-enabled {
    --wp-admin-bar-height: 0px !important;
}

.fullwidth-enabled #wpcontent,
.fullwidth-enabled #wpbody,
.fullwidth-enabled #wpbody-content {
    margin-left: 0 !important;
    padding: 0 !important;
}

.fullwidth-enabled #wpbody-content {
    padding-bottom: 0 !important;
}

a.button.button-secondary.sifency-admin-btn.sifency-deactive-licence{
    background: var(--sifency-danger-color);
    color: #fff;
    border: none;
    height: 40px;
    display: inline-flex;
    align-items: center;
}