/**
 * Modern Inventory Management UI - Shadcn UI Light Theme
 * Clean, minimal, professional design
 */

/* ==================== CSS Variables (Shadcn Style) ==================== */
:root {
    /* Colors - Shadcn Light Theme */
    --background: 0 0% 100%;
    --foreground: 222.2 84% 4.9%;

    --card: 0 0% 100%;
    --card-foreground: 222.2 84% 4.9%;

    --popover: 0 0% 100%;
    --popover-foreground: 222.2 84% 4.9%;

    --primary: 221.2 83.2% 53.3%;
    --primary-foreground: 210 40% 98%;

    --secondary: 210 40% 96.1%;
    --secondary-foreground: 222.2 47.4% 11.2%;

    --muted: 210 40% 96.1%;
    --muted-foreground: 215.4 16.3% 46.9%;

    --accent: 210 40% 96.1%;
    --accent-foreground: 222.2 47.4% 11.2%;

    --destructive: 0 84.2% 60.2%;
    --destructive-foreground: 210 40% 98%;

    --border: 214.3 31.8% 91.4%;
    --input: 214.3 31.8% 91.4%;
    --ring: 221.2 83.2% 53.3%;

    --radius: 0.5rem;
}

/* ==================== Shadcn UI Font Import ==================== */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ==================== Global Overrides ==================== */
#header {
    background: #161e33 !important;
}

/* Hide WordPress Admin Bar on Frontend */
#wpadminbar {
    display: none !important;
}

html {
    margin-top: 0 !important;
}

body.admin-bar {
    margin-top: 0 !important;

}

body {
    padding-top: 0 !important;
    font-family: 'Inter', sans-serif;
    font-size: 14px;
    font-weight: 400;
    line-height: 1.5;
    color: #333;
    background-color: #f9fafc;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

.content-area {
    background: #fff;
    border-radius: 12px;
    padding: 30px;
    margin: 15px;
    box-shadow: rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0) 0px 0px 0px 0px, rgba(0, 0, 0, 0.1) 0px 4px 6px -1px, rgba(0, 0, 0, 0.1) 0px 2px 4px -1px;

}

.inv-manage-sidebar {
    padding: 1rem 0;
}

/* ==================== Base Styles ==================== */
.imp-modern-ui {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 1rem 2rem 1rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Cantarell', sans-serif;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

[x-cloak] {
    display: none !important;
}

/* ==================== Sidebar Styles ==================== */
.inv-manage-sidebar {
    background: hsl(var(--card));
    border-right: 1px solid hsl(var(--border));
    min-height: 100vh;
    padding: 1.5rem 0;
}

.inv-manage-sidebar #logo {
    padding: 0 1.5rem;
    margin-bottom: 1.5rem;
}

.inv-manage-sidebar #logo img {
    max-width: 100%;
    height: auto;
}

/* Quick Create Button */
.inv-quick-create {
    padding: 0 1rem;
    margin-bottom: 1.5rem;
}

.inv-quick-create-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    width: 100%;
    padding: 0.875rem 1.25rem;
    background: hsl(var(--foreground));
    color: hsl(var(--background));
    text-decoration: none !important;
    font-size: 0.9375rem;
    font-weight: 600;
    border-radius: var(--radius);
    transition: all 0.2s;
    border: none;
}

.inv-quick-create-btn svg {
    flex-shrink: 0;
}

.inv-quick-create-btn:hover {
    background: hsl(var(--foreground) / 0.9);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    text-decoration: none !important;
}

.inv-quick-create-btn:active {
    transform: translateY(0);
}

/* Sidebar Menu */
.inv-sidebar-menu {
    list-style: none;
    padding: 0;
    margin: 0 0 2rem 0;
}

.inv-sidebar-menu li {
    margin: 0;
}

.inv-sidebar-menu li a {
    display: flex;
    align-items: center;
    gap: 0.875rem;
    padding: 0.75rem 1.5rem;
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: all 0.2s;
    position: relative;
}

.inv-sidebar-menu li a svg {
    flex-shrink: 0;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.inv-sidebar-menu li a:hover {
    color: hsl(var(--foreground));
    background: hsl(var(--accent) / 0.5);
}

.inv-sidebar-menu li a:hover svg {
    opacity: 1;
}

.inv-sidebar-menu li.active a {
    color: hsl(var(--foreground));
    background: hsl(var(--accent));
    font-weight: 600;
}

.inv-sidebar-menu li.active a svg {
    opacity: 1;
}

/* Sidebar Footer */
.inv-sidebar-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 16.666667%;
    /* col-xl-2 */
    padding: 1.5rem;
    border-top: 1px solid hsl(var(--border));
    background: hsl(var(--card));
}

.inv-logout-btn {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.625rem 1rem;
    color: hsl(var(--muted-foreground));
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    transition: all 0.2s;
    justify-content: center;
}

.inv-logout-btn svg {
    flex-shrink: 0;
}

.inv-logout-btn:hover {
    background: hsl(var(--destructive));
    color: white;
    border-color: hsl(var(--destructive));
}

/* Content Area */
.inv-content-area {
    padding: 1rem;
    min-height: 100vh;
}

.inv-login-required {
    text-align: center;
    padding: 4rem 2rem;
}

.inv-login-required p {
    font-size: 1.125rem;
    color: hsl(var(--muted-foreground));
    margin-bottom: 1.5rem;
}

/* Responsive */
@media (max-width: 768px) {
    .inv-sidebar-footer {
        position: relative;
        width: 100%;
    }

    .inv-manage-sidebar {
        min-height: auto;
        border-right: none;
        border-bottom: 1px solid hsl(var(--border));
    }

    .inv-quick-create {
        margin-bottom: 1rem;
    }
}

/* ==================== Statistics Cards ==================== */
.imp-stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 2rem;
}

.imp-stat-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.25rem;
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    transition: all 0.2s;
}

.imp-stat-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
}

.imp-stat-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: calc(var(--radius) * 1.5);
    flex-shrink: 0;
}

.imp-stat-icon svg {
    width: 1.5rem;
    height: 1.5rem;
    stroke-width: 2;
}

.imp-stat-icon-blue {
    background: hsl(221 83% 53% / 0.1);
    color: hsl(221 83% 53%);
}

.imp-stat-icon-gray {
    background: hsl(215 16% 47% / 0.1);
    color: hsl(215 16% 47%);
}

.imp-stat-icon-green {
    background: hsl(142 71% 45% / 0.1);
    color: hsl(142 71% 45%);
}

.imp-stat-icon-yellow {
    background: hsl(45 93% 47% / 0.1);
    color: hsl(45 93% 47%);
}

.imp-stat-content {
    flex: 1;
    min-width: 0;
}

.imp-stat-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: hsl(var(--muted-foreground));
    margin-bottom: 0.25rem;
}

.imp-stat-value {
    font-size: 1.875rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}

/* Responsive Grid */
@media (max-width: 1200px) {
    .imp-stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    .imp-stats-grid {
        grid-template-columns: 1fr;
    }
}

/* ==================== Header ==================== */
.imp-header {
    margin-bottom: 2rem;
}

.imp-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.imp-title {
    font-size: 1.875rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    margin: 0 0 0.25rem 0;
    letter-spacing: -0.025em;
    line-height: 1.2;
}

.imp-subtitle {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
    margin: 0;
    line-height: 1.5;
    font-weight: 400;
}

/* ==================== Buttons (Shadcn Style) ==================== */
.imp-btn-primary,
.imp-btn-secondary,
.imp-btn-danger {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius);
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    white-space: nowrap;
    text-decoration: none !important;
}

.imp-btn-primary {
    background: hsl(var(--primary));
    color: hsl(var(--primary-foreground));
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.imp-btn-primary:hover {
    background: hsl(var(--primary) / 0.9);
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1);
    text-decoration: none !important;
}

.imp-btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.imp-btn-secondary {
    background: hsl(var(--secondary));
    color: hsl(var(--secondary-foreground));
    border: 1px solid hsl(var(--border));
}

.imp-btn-secondary:hover {
    background: hsl(var(--secondary) / 0.8);
}

.imp-btn-danger {
    background: hsl(var(--destructive));
    color: hsl(var(--destructive-foreground));
}

.imp-btn-danger:hover {
    background: hsl(var(--destructive) / 0.9);
}

/* Icons */
.imp-icon {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
}

/* ==================== Filters & Search ==================== */
.imp-filters {
    display: flex;
    gap: 0.75rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.imp-search-wrapper {
    flex: 1;
    min-width: 250px;
    position: relative;
}

.imp-search-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1rem;
    height: 1rem;
    color: hsl(var(--muted-foreground));
}

.imp-search-input {
    width: 100%;
    height: 2.5rem;
    padding: 0 0.75rem 0 2.5rem;
    border: 1px solid hsl(var(--input));
    border-radius: var(--radius);
    font-size: 0.875rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    transition: all 0.2s;
}

.imp-search-input:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 2px hsl(var(--ring) / 0.2);
}

.imp-search-input::placeholder {
    color: hsl(var(--muted-foreground));
}

.imp-filter-group {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    width: 100%;
    align-items: center;
    justify-content: space-between;

}

.imp-select {
    height: 2.5rem;
    padding: 0 2rem 0 0.75rem;
    border: 1px solid hsl(var(--input));
    border-radius: var(--radius);
    font-size: 0.875rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    cursor: pointer;
    transition: all 0.2s;
    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 8 4 4 4-4'/%3E%3C/svg%3E");
    background-position: right 0.5rem center;
    background-repeat: no-repeat;
    background-size: 1.25rem;
}

.imp-reset-btn {
    height: 2.5rem;
    padding: 0 1rem;
    background-color: #ef4444; /* Kırmızı renk */
    color: white;
    border: none;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
}

.imp-reset-btn:hover {
    background-color: #dc2626; /* Daha koyu kırmızı */
}

.imp-reset-btn:active {
    transform: scale(0.98);
}

.imp-select:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 2px hsl(var(--ring) / 0.2);
}

/* ==================== Loading State ==================== */
.imp-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    color: hsl(var(--muted-foreground));
}

.imp-spinner {
    width: 2rem;
    height: 2rem;
    border: 3px solid hsl(var(--border));
    border-top-color: hsl(var(--primary));
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 0.75rem;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ==================== Alert ==================== */
.imp-alert-error {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 1rem;
    background: hsl(var(--destructive) / 0.1);
    border: 1px solid hsl(var(--destructive) / 0.3);
    border-radius: var(--radius);
    color: hsl(var(--destructive));
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
}

.imp-alert-icon {
    width: 1.25rem;
    height: 1.25rem;
    flex-shrink: 0;
}

/* ==================== View Toggle ==================== */
.imp-view-toggle {
    display: inline-flex;
    background: hsl(var(--muted) / 0.5);
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    padding: 0.25rem;
    gap: 0.25rem;
}

.imp-view-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.5rem 0.75rem;
    background: transparent;
    border: none;
    border-radius: calc(var(--radius) - 2px);
    color: hsl(var(--muted-foreground));
    cursor: pointer;
    transition: all 0.15s cubic-bezier(0.4, 0, 0.2, 1);
    font-weight: 500;
    position: relative;
}

.imp-view-btn:hover:not(.active) {
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.imp-view-btn.active {
    background: hsl(var(--background));
    color: hsl(var(--primary));
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    font-weight: 600;
}

.imp-view-btn.active::after {
    content: '';
    position: absolute;
    bottom: 0.25rem;
    left: 50%;
    transform: translateX(-50%);
    width: 1rem;
    height: 2px;
    background: hsl(var(--primary));
    border-radius: 2px;
}

.imp-view-btn .imp-icon {
    width: 1rem;
    height: 1rem;
}

/* ==================== List View ==================== */
.imp-list-view {
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    overflow: hidden;
    margin-bottom: 2rem;
}

.imp-list-header {
    display: grid;
    grid-template-columns: 80px 2fr 100px 140px 140px 100px 100px 100px;
    gap: 1rem;
    padding: 0.75rem 1rem;
    background: hsl(var(--muted) / 0.5);
    border-bottom: 1px solid hsl(var(--border));
    font-size: 0.6875rem;
    font-weight: 600;
    color: hsl(var(--muted-foreground));
    text-transform: uppercase;
    letter-spacing: 0.08em;
    line-height: 1.5;
}

.imp-list-row {
    display: grid;
    grid-template-columns: 80px 2fr 100px 140px 140px 100px 100px 100px;
    gap: 1rem;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid hsl(var(--border));
    align-items: center;
    transition: background 0.2s;
}

.imp-list-row:last-child {
    border-bottom: none;
}

.imp-list-row:hover {
    background: hsl(var(--muted) / 0.3);
}

/* Title with Stock Number */
.imp-title-wrapper {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.imp-list-title {
    font-weight: 500;
    color: hsl(var(--foreground));
    line-height: 1.4;
}

.imp-stock-number {
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
    font-weight: 400;
}

.imp-list-col {
    font-size: 0.875rem;
    color: hsl(var(--foreground));
}

.imp-list-thumbnail {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: calc(var(--radius) - 2px);
    border: 1px solid hsl(var(--border));
}

.imp-list-title {
    font-weight: 600;
    letter-spacing: -0.01em;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.imp-list-price {
    font-weight: 700;
    color: hsl(var(--primary));
    letter-spacing: -0.02em;
    font-feature-settings: 'tnum';
    font-variant-numeric: tabular-nums;
}

.imp-list-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: calc(var(--radius) - 2px);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.imp-list-badge.imp-badge-active {
    background: hsl(142.1 76.2% 36.3% / 0.15);
    color: hsl(142.1 76.2% 36.3%);
}

.imp-list-badge.imp-badge-pending {
    background: hsl(47.9 95.8% 53.1% / 0.15);
    color: hsl(26 83.3% 14.1%);
}

.imp-list-badge.imp-badge-sold {
    background: hsl(var(--destructive) / 0.15);
    color: hsl(var(--destructive));
}

.imp-list-badge.imp-badge-inactive {
    background: hsl(215 16% 47% / 0.15);
    color: hsl(215 16% 47%);
}

.imp-list-actions {
    display: flex;
    gap: 0.25rem;
}

.imp-btn-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2rem;
    height: 2rem;
    padding: 0;
    background: hsl(var(--background));
    border: 1px solid hsl(var(--border));
    border-radius: calc(var(--radius) - 2px);
    color: hsl(var(--foreground));
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    position: relative;
}

.imp-btn-icon:hover {
    background: hsl(var(--muted));
    border-color: hsl(var(--primary));
    color: hsl(var(--primary));
}

.imp-btn-icon-danger:hover {
    background: hsl(var(--destructive) / 0.1);
    border-color: hsl(var(--destructive));
    color: hsl(var(--destructive));
}

.imp-btn-icon .imp-icon {
    width: 1rem;
    height: 1rem;
}

/* ==================== Tooltip ==================== */

.imp-btn-icon[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 0.5rem;
    padding: 0.375rem 0.75rem;
    background: hsl(var(--popover));
    color: hsl(var(--popover-foreground));
    border: 1px solid hsl(var(--border));
    border-radius: calc(var(--radius) - 2px);
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    z-index: 1000;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    pointer-events: none;
    opacity: 0;
    animation: tooltipFadeIn 0.2s ease-out forwards;
}

.imp-btn-icon[data-tooltip]:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 0.25rem;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid hsl(var(--border));
    z-index: 1001;
    opacity: 0;
    animation: tooltipFadeIn 0.2s ease-out forwards;
}

@keyframes tooltipFadeIn {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(4px);
    }

    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.imp-btn-icon[data-tooltip]:hover::before {
    animation: tooltipFadeIn 0.2s ease-out forwards;
}

/* Tooltip for secondary and danger buttons */
.imp-btn-secondary[data-tooltip],
.imp-btn-danger[data-tooltip] {
    position: relative;
}

.imp-btn-secondary[data-tooltip]:hover::after,
.imp-btn-danger[data-tooltip]:hover::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 0.5rem;
    padding: 0.375rem 0.75rem;
    background: hsl(var(--popover));
    color: hsl(var(--popover-foreground));
    border: 1px solid hsl(var(--border));
    border-radius: calc(var(--radius) - 2px);
    font-size: 0.75rem;
    font-weight: 500;
    white-space: nowrap;
    z-index: 1000;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    pointer-events: none;
    opacity: 0;
    animation: tooltipFadeIn 0.2s ease-out forwards;
}

.imp-btn-secondary[data-tooltip]:hover::before,
.imp-btn-danger[data-tooltip]:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    margin-bottom: 0.25rem;
    width: 0;
    height: 0;
    border-left: 5px solid transparent;
    border-right: 5px solid transparent;
    border-top: 5px solid hsl(var(--border));
    z-index: 1001;
    opacity: 0;
    animation: tooltipFadeIn 0.2s ease-out forwards;
}

/* ==================== Grid Layout ==================== */
.imp-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.25rem;
    margin-bottom: 2rem;
}

/* ==================== Card (Shadcn Style) ==================== */
.imp-card {
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    overflow: hidden;
    transition: all 0.2s;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
}

.imp-card:hover {
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    border-color: hsl(var(--border) / 0.8);
}

.imp-card-image {
    position: relative;
    width: 100%;
    height: 180px;
    overflow: hidden;
    background: hsl(var(--muted));
}

.imp-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.imp-badge {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    padding: 0.25rem 0.625rem;
    font-size: 0.6875rem;
    font-weight: 600;
    border-radius: calc(var(--radius) - 2px);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    backdrop-filter: blur(8px);
}

.imp-badge-active {
    background: hsl(142.1 76.2% 36.3% / 0.9);
    color: white;
}

.imp-badge-pending {
    background: hsl(47.9 95.8% 53.1% / 0.9);
    color: hsl(26 83.3% 14.1%);
}

.imp-badge-sold {
    background: hsl(var(--destructive) / 0.9);
    color: white;
}

.imp-badge-inactive {
    background: hsl(215 16% 47% / 0.9);
    color: white;
}

.imp-card-content {
    padding: 1rem;
}

.imp-card-title {
    font-size: 1rem;
    font-weight: 600;
    color: hsl(var(--card-foreground));
    margin: 0 0 0.25rem 0;
    line-height: 1.5;
    letter-spacing: -0.01em;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.imp-card-stock {
    font-size: 0.75rem;
    color: hsl(var(--muted-foreground));
    margin: 0 0 0.75rem 0;
    font-weight: 400;
}

.imp-card-details {
    display: flex;
    flex-direction: column;
    gap: 0.375rem;
    margin-bottom: 0.75rem;
}

.imp-detail-row {
    display: flex;
    justify-content: space-between;
    font-size: 0.8125rem;
}

.imp-label {
    color: hsl(var(--muted-foreground));
    font-weight: 500;
}

.imp-value {
    color: hsl(var(--foreground));
    font-weight: 600;
}

.imp-price-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.75rem;
    border-top: 1px solid hsl(var(--border));
    margin-top: 0.5rem;
}

.imp-price-label {
    font-size: 0.6875rem;
    color: hsl(var(--muted-foreground));
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 0.25rem 0;
    font-weight: 500;
}

.imp-price {
    font-size: 1.25rem;
    font-weight: 700;
    color: hsl(var(--primary));
    margin: 0;
    letter-spacing: -0.02em;
    font-feature-settings: 'tnum';
    font-variant-numeric: tabular-nums;
}

.imp-tag {
    padding: 0.25rem 0.5rem;
    background: hsl(var(--primary) / 0.1);
    color: hsl(var(--primary));
    border-radius: calc(var(--radius) - 2px);
    font-size: 0.6875rem;
    font-weight: 600;
}

.imp-card-actions {
    display: flex;
    gap: 0.375rem;
    padding: 0.75rem;
    background: hsl(var(--muted) / 0.5);
    border-top: 1px solid hsl(var(--border));
}

.imp-card-actions .imp-btn-secondary,
.imp-card-actions .imp-btn-danger {
    flex: 1;
    padding: 0.375rem 0.625rem;
    font-size: 0.8125rem;
}

/* ==================== Empty State ==================== */
.imp-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 4rem 2rem;
    text-align: center;
}

.imp-empty-icon {
    width: 3.5rem;
    height: 3.5rem;
    color: hsl(var(--muted-foreground) / 0.5);
    margin-bottom: 1rem;
}

.imp-empty-state h3 {
    font-size: 1.125rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    margin: 0 0 0.5rem 0;
}

.imp-empty-state p {
    color: hsl(var(--muted-foreground));
    margin: 0 0 1.5rem 0;
    font-size: 0.875rem;
}

/* ==================== Pagination ==================== */
.imp-pagination {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 0;
    border-top: 1px solid hsl(var(--border));
}

.imp-pagination-info {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
}

.imp-pagination-buttons {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.imp-pagination-btn {
    padding: 0.375rem 0.875rem;
    background: hsl(var(--background));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    color: hsl(var(--foreground));
    cursor: pointer;
    transition: all 0.2s;
}

.imp-pagination-btn:hover:not(:disabled) {
    background: hsl(var(--muted));
}

.imp-pagination-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.imp-pagination-current {
    font-size: 0.875rem;
    color: hsl(var(--foreground));
    font-weight: 500;
}

/* ==================== Inline Edit ==================== */
.imp-editable-field {
    position: relative;
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.5rem;
    border-radius: calc(var(--radius) - 2px);
    cursor: pointer;
    transition: all 0.2s;
}

.imp-editable-field:hover {
    background: hsl(var(--muted) / 0.5);
}

.imp-editable-field.editing {
    background: hsl(var(--primary) / 0.1);
    border: 1px solid hsl(var(--primary) / 0.3);
}

.imp-edit-icon {
    width: 0.875rem;
    height: 0.875rem;
    opacity: 0;
    color: hsl(var(--muted-foreground));
    transition: opacity 0.2s;
}

.imp-editable-field:hover .imp-edit-icon {
    opacity: 1;
}

.imp-edit-popup {
    background: hsl(var(--popover));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    max-width: 400px;
    width: 100%;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    animation: scaleIn 0.2s ease-out;
}

.imp-edit-popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    border-bottom: 1px solid hsl(var(--border));
}

.imp-edit-popup-header h3 {
    font-size: 1rem;
    font-weight: 600;
    color: hsl(var(--popover-foreground));
    margin: 0;
}

.imp-edit-popup-body {
    padding: 1rem;
}

.imp-edit-popup-body>div {
    margin-bottom: 1rem;
}

.imp-edit-popup-body>div:last-child {
    margin-bottom: 0;
}

.imp-edit-popup-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid hsl(var(--border));
}

.imp-edit-popup-footer .imp-btn-primary {
    background: hsl(var(--primary)) !important;
    color: hsl(var(--primary-foreground)) !important;
    font-weight: 600;
}

.imp-edit-popup-footer .imp-btn-primary:hover:not(:disabled) {
    background: hsl(var(--primary) / 0.9) !important;
}

.imp-edit-popup-footer .imp-btn-secondary {
    background: hsl(var(--background)) !important;
    color: hsl(var(--foreground)) !important;
    border: 1px solid hsl(var(--border));
}

.imp-edit-popup-footer .imp-btn-secondary:hover {
    background: hsl(var(--muted)) !important;
}

/* ==================== Modal (Shadcn Style) ==================== */
.imp-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 1rem;
    animation: fadeIn 0.2s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.imp-modal {
    background: hsl(var(--popover));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    animation: scaleIn 0.2s ease-out;
}

@keyframes scaleIn {
    from {
        transform: scale(0.95);
        opacity: 0;
    }

    to {
        transform: scale(1);
        opacity: 1;
    }
}

.imp-modal-sm {
    max-width: 400px;
}

.imp-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.25rem;
    border-bottom: 1px solid hsl(var(--border));
}

.imp-modal-header h2 {
    font-size: 1.125rem;
    font-weight: 600;
    color: hsl(var(--popover-foreground));
    margin: 0;
}

.imp-modal-close {
    padding: 0.25rem;
    background: none;
    border: none;
    color: hsl(var(--muted-foreground));
    cursor: pointer;
    border-radius: calc(var(--radius) - 2px);
    transition: all 0.2s;
}

.imp-modal-close:hover {
    background: hsl(var(--muted));
    color: hsl(var(--foreground));
}

.imp-modal-body {
    padding: 1.25rem;
}

.imp-modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    padding: 1.25rem;
    border-top: 1px solid hsl(var(--border));
    background: hsl(var(--muted) / 0.3);
}

.imp-modal-footer .imp-btn-primary {
    background: hsl(var(--primary)) !important;
    color: hsl(var(--primary-foreground)) !important;
    font-weight: 600;
}

.imp-modal-footer .imp-btn-primary:hover:not(:disabled) {
    background: hsl(var(--primary) / 0.9) !important;
}

.imp-modal-footer .imp-btn-secondary {
    background: hsl(var(--background)) !important;
    color: hsl(var(--foreground)) !important;
    border: 1px solid hsl(var(--border));
}

.imp-modal-footer .imp-btn-secondary:hover {
    background: hsl(var(--muted)) !important;
}

.imp-modal-footer .imp-btn-danger {
    background: hsl(var(--destructive)) !important;
    color: hsl(var(--destructive-foreground)) !important;
    font-weight: 600;
}

.imp-modal-footer .imp-btn-danger:hover:not(:disabled) {
    background: hsl(var(--destructive) / 0.9) !important;
}

/* ==================== Form (Shadcn Style) ==================== */
.imp-form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.imp-form-group {
    display: flex;
    flex-direction: column;
}

.imp-form-full {
    grid-column: 1 / -1;
}

.imp-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: hsl(var(--foreground));
    margin-bottom: 0.375rem;
    line-height: 1.5;
    letter-spacing: -0.005em;
}

.imp-input {
    height: 2.5rem;
    padding: 0 0.75rem;
    border: 1px solid hsl(var(--input));
    border-radius: var(--radius);
    font-size: 0.875rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    transition: all 0.2s;
}

.imp-input:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 2px hsl(var(--ring) / 0.2);
}

textarea.imp-input {
    height: auto;
    min-height: 5rem;
    padding: 0.625rem 0.75rem;
    resize: vertical;
    font-family: inherit;
}

/* ==================== Toast Notifications ==================== */
.imp-toast {
    position: fixed;
    bottom: 1.5rem;
    right: 1.5rem;
    padding: 0.875rem 1.25rem;
    border-radius: var(--radius);
    font-size: 0.875rem;
    font-weight: 500;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    z-index: 10000;
    animation: slideIn 0.3s ease-out;
    max-width: 350px;
    border: 1px solid hsl(var(--border));
}

@keyframes slideIn {
    from {
        transform: translateX(calc(100% + 2rem));
        opacity: 0;
    }

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

.imp-toast-success {
    background: hsl(var(--background));
    color: hsl(142.1 76.2% 36.3%);
    border-color: hsl(142.1 76.2% 36.3% / 0.3);
}

.imp-toast-error {
    background: hsl(var(--background));
    color: hsl(var(--destructive));
    border-color: hsl(var(--destructive) / 0.3);
}

/* ==================== Responsive Design ==================== */
@media (max-width: 1024px) {

    .imp-list-header,
    .imp-list-row {
        grid-template-columns: 60px 2fr 120px 120px 120px;
        font-size: 0.8125rem;
    }

    .imp-col-broker,
    .imp-col-location {
        display: none;
    }

    .imp-stock-number {
        font-size: 0.6875rem;
    }
}

@media (max-width: 768px) {
    .imp-modern-ui {
        padding: 1rem;
    }

    .imp-title {
        font-size: 1.5rem;
    }

    .imp-subtitle {
        font-size: 0.8125rem;
    }

    .imp-filters {
        flex-direction: column;
    }

    .imp-filter-group {
        width: 100%;
        justify-content: space-between;
    }

    .imp-select {
        flex: 1;
        min-width: 0;
    }

    .imp-view-toggle {
        order: -1;
    }

    /* List view mobile */
    .imp-list-view {
        border: none;
        background: transparent;
    }

    .imp-list-header {
        display: none;
    }

    .imp-list-row {
        display: flex;
        flex-direction: column;
        gap: 0.75rem;
        padding: 1rem;
        background: hsl(var(--card));
        border: 1px solid hsl(var(--border));
        border-radius: var(--radius);
        margin-bottom: 0.75rem;
    }

    .imp-list-row:hover {
        background: hsl(var(--card));
    }

    .imp-list-col {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }

    .imp-col-image {
        justify-content: center;
    }

    .imp-list-thumbnail {
        width: 100%;
        height: 180px;
        border-radius: calc(var(--radius) - 2px);
    }

    .imp-list-col::before {
        content: attr(data-label);
        font-weight: 600;
        color: hsl(var(--muted-foreground));
        font-size: 0.75rem;
        text-transform: uppercase;
        letter-spacing: 0.05em;
    }

    .imp-col-image::before,
    .imp-col-actions::before {
        display: none;
    }

    .imp-list-actions {
        justify-content: flex-end;
        width: 100%;
    }

    /* Grid view mobile */
    .imp-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }

    .imp-pagination {
        flex-direction: column;
        gap: 1rem;
    }

    .imp-form-grid {
        grid-template-columns: 1fr;
    }

    .imp-modal {
        margin: 0;
        max-height: 100vh;
        border-radius: 0;
    }

    .imp-toast {
        left: 1rem;
        right: 1rem;
        bottom: 1rem;
    }
}

@media (max-width: 480px) {
    .imp-card-actions {
        flex-direction: column;
    }

    .imp-card-actions .imp-btn-secondary,
    .imp-card-actions .imp-btn-danger {
        width: 100%;
    }
}

/* ==================== Modern Login Form (Shadcn Style) ==================== */
.imp-auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, hsl(var(--muted)) 0%, hsl(var(--background)) 100%);
    padding: 2rem 1rem;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.imp-auth-container {
    width: 100%;
    max-width: 420px;
}

.imp-auth-card {
    background: hsl(var(--card));
    border: 1px solid hsl(var(--border));
    border-radius: calc(var(--radius) + 4px);
    padding: 2.5rem;
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    animation: slideUp 0.4s ease-out;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

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

/* Header */
.imp-auth-header {
    text-align: center;
    margin-bottom: 2rem;
}

.imp-auth-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    max-width: 180px;
    height: auto;
    margin-bottom: 1.5rem;
}

/* Logo image from settings */
.imp-auth-logo-img {
    max-width: 100%;
    height: auto;
    object-fit: contain;
}

/* Fallback icon when no logo is set */
.imp-auth-logo:has(.imp-logo-icon) {
    width: 4rem;
    height: 4rem;
    background: hsl(var(--primary) / 0.1);
    border-radius: 50%;
}

.imp-logo-icon {
    width: 2rem;
    height: 2rem;
    color: hsl(var(--primary));
}

.imp-auth-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: hsl(var(--foreground));
    margin: 0 0 0.5rem 0;
    letter-spacing: -0.025em;
    line-height: 1.2;
}

.imp-auth-subtitle {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
    margin: 0;
    line-height: 1.5;
}

/* Alert Messages */
.imp-auth-alert {
    padding: 0.875rem 1rem;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
    line-height: 1.5;
    animation: fadeIn 0.3s ease-out;
}

.imp-auth-alert.success {
    background: hsl(142.1 76.2% 36.3% / 0.1);
    color: hsl(142.1 76.2% 36.3%);
    border: 1px solid hsl(142.1 76.2% 36.3% / 0.3);
}

.imp-auth-alert.error {
    background: hsl(var(--destructive) / 0.1);
    color: hsl(var(--destructive));
    border: 1px solid hsl(var(--destructive) / 0.3);
}

/* Form */
.imp-auth-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.imp-auth-field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.imp-auth-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.imp-auth-label {
    font-size: 0.875rem;
    font-weight: 600;
    color: hsl(var(--foreground));
    letter-spacing: -0.005em;
}

.imp-auth-link-small {
    font-size: 0.8125rem;
    color: hsl(var(--primary));
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s;
}

.imp-auth-link-small:hover {
    color: hsl(var(--primary) / 0.8);
    text-decoration: underline;
}

.imp-auth-input-wrapper {
    position: relative;
}

.imp-input-icon {
    position: absolute;
    left: 0.875rem;
    top: 50%;
    transform: translateY(-50%);
    width: 1.125rem;
    height: 1.125rem;
    color: hsl(var(--muted-foreground));
    pointer-events: none;
}

.imp-auth-input {
    width: 100%;
    height: 2.75rem;
    padding: 0 1rem 0 3rem;
    border: 1px solid hsl(var(--input));
    border-radius: var(--radius);
    font-size: 0.875rem;
    background: hsl(var(--background));
    color: hsl(var(--foreground));
    transition: all 0.2s;
}

.imp-auth-input:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 3px hsl(var(--ring) / 0.1);
}

.imp-auth-input::placeholder {
    color: hsl(var(--muted-foreground) / 0.7);
}

/* Checkbox */
.imp-auth-checkbox-group {
    margin: 0.25rem 0;
}

.imp-auth-checkbox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
    user-select: none;
}

.imp-checkbox-input {
    width: 1rem;
    height: 1rem;
    border: 1px solid hsl(var(--input));
    border-radius: calc(var(--radius) - 2px);
    cursor: pointer;
    accent-color: hsl(var(--primary));
}

.imp-checkbox-label {
    font-size: 0.875rem;
    color: hsl(var(--foreground));
    line-height: 1.5;
}

/* Submit Button */
.imp-auth-button {
    width: 100%;
    height: 2.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: hsl(var(--primary));
    color: hsl(var(--primary-foreground));
    border: none;
    border-radius: var(--radius);
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    margin-top: 0.5rem;
}

.imp-auth-button:hover {
    background: hsl(var(--primary) / 0.9);
    transform: translateY(-1px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.imp-auth-button:active {
    transform: translateY(0);
}

.imp-auth-button:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none;
}

.imp-button-text {
    line-height: 1;
}

.imp-button-icon {
    width: 1.125rem;
    height: 1.125rem;
    transition: transform 0.2s;
}

.imp-auth-button:hover .imp-button-icon {
    transform: translateX(2px);
}

/* Footer */
.imp-auth-footer {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid hsl(var(--border));
    text-align: center;
}

.imp-auth-footer-text {
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
    margin: 0;
}

.imp-auth-link {
    color: hsl(var(--primary));
    text-decoration: none;
    font-weight: 600;
    transition: color 0.2s;
}

.imp-auth-link:hover {
    color: hsl(var(--primary) / 0.8);
    text-decoration: underline;
}

/* Info Section */
.imp-auth-info {
    margin-top: 1.5rem;
    text-align: center;
}

.imp-auth-info-text {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8125rem;
    color: hsl(var(--muted-foreground));
    margin: 0;
}

.imp-info-icon {
    width: 1rem;
    height: 1rem;
    flex-shrink: 0;
}

/* Responsive */
@media (max-width: 480px) {
    .imp-auth-wrapper {
        padding: 1rem;
    }

    .imp-auth-card {
        padding: 2rem 1.5rem;
    }

    .imp-auth-title {
        font-size: 1.5rem;
    }

    .imp-auth-logo {
        max-width: 150px;
    }

    /* Fallback icon on mobile */
    .imp-auth-logo:has(.imp-logo-icon) {
        width: 3.5rem;
        height: 3.5rem;
    }

    .imp-logo-icon {
        width: 1.75rem;
        height: 1.75rem;
    }
}

/* Loading State */
.imp-auth-button.loading {
    position: relative;
    color: transparent;
}

.imp-auth-button.loading::after {
    content: '';
    position: absolute;
    width: 1rem;
    height: 1rem;
    border: 2px solid hsl(var(--primary-foreground) / 0.3);
    border-top-color: hsl(var(--primary-foreground));
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

/* ==================== Print Styles ==================== */
@media print {

    .imp-filters,
    .imp-btn-primary,
    .imp-btn-secondary,
    .imp-btn-danger,
    .imp-card-actions,
    .imp-pagination {
        display: none !important;
    }

    .imp-card {
        break-inside: avoid;
    }
}

/* ==================== Accessibility ==================== */
.imp-btn-primary:focus-visible,
.imp-btn-secondary:focus-visible,
.imp-btn-danger:focus-visible,
.imp-search-input:focus-visible,
.imp-select:focus-visible,
.imp-input:focus-visible {
    outline: 2px solid hsl(var(--ring));
    outline-offset: 2px;
}

/* ==================== Loading skeleton (optional) ==================== */
@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.5;
    }
}

.imp-skeleton {
    background: hsl(var(--muted));
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
    border-radius: var(--radius);
}

/* ==================== Form Pages - Meta Info & Danger Zone ==================== */
.imp-meta-info {
    display: flex;
    gap: 2rem;
    flex-wrap: wrap;
    padding: 1rem 1.5rem;
    background: hsl(var(--muted));
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
    font-size: 0.875rem;
}

.imp-meta-info span {
    color: hsl(var(--muted-foreground));
}

.imp-meta-info strong {
    color: hsl(var(--foreground));
    font-weight: 600;
}

.imp-danger-zone {
    margin-top: 3rem;
    padding: 1.5rem;
    background: hsl(0 84.2% 97.3%);
    border: 1px solid hsl(var(--destructive));
    border-radius: var(--radius);
}

.imp-danger-zone h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.125rem;
    font-weight: 600;
    color: hsl(var(--destructive));
}

.imp-danger-zone p {
    margin: 0 0 1rem 0;
    font-size: 0.875rem;
    color: hsl(var(--muted-foreground));
}

.imp-danger-zone .imp-btn-danger {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

/* ==================== ACF Form Overrides ==================== */
.acf-form {
    margin-top: 1.5rem;
}

.acf-form .acf-fields {
    border: none !important;
}

.acf-form .acf-field {
    padding: 1rem 0 !important;
    border: none !important;
    display: flex !important;
    align-items: flex-start !important;
    gap: 2rem !important;
}

.acf-form .acf-label {
    font-weight: 500;
    margin-bottom: 0 !important;
    width: 200px !important;
    flex-shrink: 0 !important;
    padding-top: 0.5rem !important;
    font-size: 0.875rem !important;
}

.acf-form .acf-label label {
    margin: 0 !important;
}

.acf-form .acf-input {
    flex: 1 !important;
    width: 100% !important;
}

.acf-form .acf-input input[type="text"],
.acf-form .acf-input input[type="number"],
.acf-form .acf-input input[type="email"],
.acf-form .acf-input textarea,
.acf-form .acf-input select {
    width: 100%;
    padding: 0.5rem 0.75rem;
    border: 1px solid hsl(var(--border));
    border-radius: var(--radius);
    font-size: 0.875rem;
    transition: all 0.2s;
}

.select2-container.-acf .select2-selection {
    border-color: #e1e7ef !important;
    height: auto !important;
    min-height: 38px !important;
}

.select2-container .select2-selection--single .select2-selection__rendered {
    padding: 0.5rem 0.75rem !important;
    line-height: 1.5 !important;
    font-size: 0.875rem !important;
}

.acf-input-prepend,
.acf-input-append {
    padding: 9px 10px !important;
    border: #e1e7ef solid 1px !important;
}

.acf-form .acf-input input:focus,
.acf-form .acf-input textarea:focus,
.acf-form .acf-input select:focus {
    outline: none;
    border-color: hsl(var(--ring));
    box-shadow: 0 0 0 3px hsla(var(--ring), 0.1);
}

/* Post Title & Content fields - full width */
.acf-form>.acf-field[data-name="post_title"],
.acf-form>.acf-field[data-name="post_content"] {
    display: flex !important;
    align-items: flex-start !important;
}

.acf-form>.acf-field[data-name="post_title"] .acf-label,
.acf-form>.acf-field[data-name="post_content"] .acf-label {
    width: 200px !important;
}

.acf-form>.acf-field[data-name="post_title"] .acf-input,
.acf-form>.acf-field[data-name="post_content"] .acf-input {
    flex: 1 !important;
}

/* ACF Tab fields - hide tab titles completely */
.acf-form .acf-field.acf-field-tab,
.acf-form .acf-field[data-type="tab"],
.acf-fields>.acf-field-tab {
    display: none !important;
    /* Tab başlıklarını tamamen gizle */
    visibility: hidden !important;
    height: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
    opacity: 0 !important;
}

/* Hide tab field labels and links */
.acf-form .acf-field-tab .acf-label,
.acf-form .acf-field-tab a,
.acf-form .acf-field-tab h4 {
    display: none !important;
}

/* Hide inactive tab content */
.acf-form .acf-field[data-type]:not(.acf-field-tab) {
    display: flex !important;
}

.acf-form .acf-field[data-type].acf-hidden {
    display: none !important;
}

/* Tab content visibility control */
.acf-form>.acf-fields>.acf-field:not(.acf-field-tab) {
    display: flex !important;
}

.acf-form>.acf-fields>.acf-field.acf-hidden {
    display: none !important;
}

.acf-form .acf-tab-wrap {
    background: hsl(var(--muted)) !important;
    border: 1px solid hsl(var(--border)) !important;
    border-radius: var(--radius) !important;
    padding: 0.25rem !important;
    margin-bottom: 1.5rem !important;
}

.acf-form .acf-tab-wrap .acf-tab-group {
    display: flex !important;
    gap: 0.25rem !important;
    border: none !important;
    padding: 0 !important;
    background: transparent !important;
}

.acf-form .acf-tab-wrap .acf-tab-button {
    flex: 1 !important;
    padding: 0.625rem 1rem !important;
    font-size: 0.875rem !important;
    font-weight: 500 !important;
    border: none !important;
    border-radius: calc(var(--radius) - 2px) !important;
    background: transparent !important;
    color: hsl(var(--muted-foreground)) !important;
    transition: all 0.2s !important;
    cursor: pointer !important;
}

.acf-form .acf-tab-wrap .acf-tab-button:hover {
    background: hsla(var(--foreground), 0.05) !important;
    color: hsl(var(--foreground)) !important;
}

/* Active tab state - multiple selectors for compatibility */
.acf-form .acf-tab-wrap li.active {
    background: hsl(var(--background)) !important;
    color: hsl(var(--foreground)) !important;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1) !important;
    font-weight: 600 !important;
    position: relative !important;
}

/* Active tab indicator (bottom border) */
.acf-form .acf-tab-wrap li.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: hsl(var(--primary));
}

/* Tab content wrapper */
.acf-form .acf-fields.-left>.acf-tab-wrap {
    margin-left: 0 !important;
}


/* Submit button */
.acf-form .acf-form-submit {
    padding-top: 30px;
    text-align: right;
}

.acf-form .acf-button {
    background: hsl(var(--primary)) !important;
    color: hsl(var(--primary-foreground)) !important;
    border: none !important;
    padding: 0.625rem 1.5rem !important;
    border-radius: var(--radius) !important;
    font-weight: 500 !important;
    font-size: 15px !important;
    cursor: pointer !important;
    transition: all 0.2s !important;
    text-decoration: none !important;
}

.acf-form .acf-button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

a.acf-button.acf-repeater-add-row.button.button-primary {
    background: #464444 !important;
    font-size: 14px !important;

}

.acf-form .acf-fields {
    border-bottom: 1px solid #ddd !important;
    padding-bottom: 30px;
}

/* Responsive - Stack on mobile */
@media (max-width: 768px) {
    .imp-meta-info {
        flex-direction: column;
        gap: 0.75rem;
    }

    .acf-form .acf-field {
        flex-direction: column !important;
        gap: 0.5rem !important;
    }

    .acf-form .acf-label {
        width: 100% !important;
        padding-top: 0 !important;
    }

    .acf-form .acf-form-submit {
        padding-left: 0 !important;
    }

    .acf-form .acf-tab-wrap .acf-tab-group {
        flex-wrap: wrap !important;
    }

    .acf-form .acf-tab-wrap .acf-tab-button {
        flex: 1 1 auto !important;
        min-width: 120px !important;
    }
}