/* ===================================
   DESIGN TOKENS & CSS VARIABLES
   =================================== */
:root {
    /* Colors - Dark theme with red accents */
    --hojayfa-color-primary-1: #dc2626;
    --hojayfa-color-primary-hover-1: #b91c1c;
    --hojayfa-color-primary-light-1: #fee2e2;
    --hojayfa-color-success-1: #10b981;
    --hojayfa-color-error-1: #ef4444;
    --hojayfa-color-warning-1: #f59e0b;
    --hojayfa-color-neutral-50-1: #1a1a1a;
    --hojayfa-color-neutral-100-1: #2a2a2a;
    --hojayfa-color-neutral-200-1: #3a3a3a;
    --hojayfa-color-neutral-300-1: #4a4a4a;
    --hojayfa-color-neutral-400-1: #6a6a6a;
    --hojayfa-color-neutral-500-1: #8a8a8a;
    --hojayfa-color-neutral-600-1: #aaaaaa;
    --hojayfa-color-neutral-700-1: #cccccc;
    --hojayfa-color-neutral-800-1: #e5e5e5;
    --hojayfa-color-neutral-900-1: #f5f5f5;
    --hojayfa-color-white-1: #ffffff;
    --hojayfa-color-bg-1: #0f0f0f;
    --hojayfa-color-card-bg-1: #1a1a1a;
    
    /* Spacing */
    --hojayfa-space-xs-1: 0.25rem;
    --hojayfa-space-sm-1: 0.5rem;
    --hojayfa-space-md-1: 1rem;
    --hojayfa-space-lg-1: 1.5rem;
    --hojayfa-space-xl-1: 2rem;
    --hojayfa-space-2xl-1: 3rem;
    
    /* Typography */
    --hojayfa-font-sans-1: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --hojayfa-font-size-xs-1: 0.75rem;
    --hojayfa-font-size-sm-1: 0.875rem;
    --hojayfa-font-size-base-1: 1rem;
    --hojayfa-font-size-lg-1: 1.125rem;
    --hojayfa-font-size-xl-1: 1.25rem;
    --hojayfa-font-size-2xl-1: 1.5rem;
    
    /* Border radius */
    --hojayfa-radius-sm-1: 0.375rem;
    --hojayfa-radius-md-1: 0.5rem;
    --hojayfa-radius-lg-1: 0.75rem;
    --hojayfa-radius-xl-1: 1rem;
    --hojayfa-radius-2xl-1: 1.5rem;
    
    /* Shadows */
    --hojayfa-shadow-sm-1: 0 1px 2px 0 rgb(0 0 0 / 0.3);
    --hojayfa-shadow-md-1: 0 4px 6px -1px rgb(0 0 0 / 0.4);
    --hojayfa-shadow-lg-1: 0 10px 15px -3px rgb(0 0 0 / 0.5);
    --hojayfa-shadow-xl-1: 0 20px 25px -5px rgb(0 0 0 / 0.6);
    
    /* Transitions */
    --hojayfa-transition-fast-1: 150ms ease-in-out;
    --hojayfa-transition-base-1: 200ms ease-in-out;
    --hojayfa-transition-slow-1: 300ms ease-in-out;
    
    /* Z-index */
    --hojayfa-z-base-1: 1;
    --hojayfa-z-dropdown-1: 100;
    --hojayfa-z-sticky-1: 200;
    --hojayfa-z-modal-1: 1000;
    --hojayfa-z-toast-1: 2000;
}

/* ===================================
   RESET & BASE STYLES
   =================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}


/* ===================================
   COMPONENT: BUTTON
   =================================== */
.hojayfa-btn-1 {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--hojayfa-space-sm-1);
    padding: 0.625rem var(--hojayfa-space-lg-1);
    font-size: var(--hojayfa-font-size-sm-1);
    font-weight: 500;
    line-height: 1.5;
    border-radius: var(--hojayfa-radius-lg-1);
    border: 1px solid transparent;
    cursor: pointer;
    transition: all var(--hojayfa-transition-fast-1);
    text-decoration: none;
    white-space: nowrap;
    min-height: 44px;
    touch-action: manipulation;
}

.hojayfa-btn-1:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.hojayfa-btn-1:focus-visible {
    outline: 2px solid var(--hojayfa-color-primary-1);
    outline-offset: 2px;
}

.hojayfa-btn-primary-1 {
    background-color: var(--hojayfa-color-primary-1);
    color: var(--hojayfa-color-white-1);
}

.hojayfa-btn-primary-1:hover:not(:disabled) {
    background-color: var(--hojayfa-color-primary-hover-1);
    transform: translateY(-1px);
    box-shadow: var(--hojayfa-shadow-md-1);
}

.hojayfa-btn-secondary-1 {
    background-color: var(--hojayfa-color-neutral-100-1);
    color: var(--hojayfa-color-neutral-700-1);
    border-color: var(--hojayfa-color-neutral-300-1);
}

.hojayfa-btn-secondary-1:hover:not(:disabled) {
    background-color: var(--hojayfa-color-neutral-200-1);
    border-color: var(--hojayfa-color-neutral-400-1);
}

.hojayfa-btn-ghost-1 {
    background-color: transparent;
    color: var(--hojayfa-color-neutral-600-1);
}

.hojayfa-btn-ghost-1:hover:not(:disabled) {
    background-color: var(--hojayfa-color-neutral-100-1);
}

.hojayfa-btn-sm-1 {
    padding: 0.375rem var(--hojayfa-space-md-1);
    font-size: var(--hojayfa-font-size-xs-1);
    min-height: 36px;
}

.hojayfa-btn-icon-1 {
    padding: 0.625rem;
    min-width: 44px;
}

.hojayfa-btn-full-1 {
    width: 100%;
}

/* ===================================
   APP TITLE
   =================================== */
.hojayfa-app-title-1 {
    text-align: center;
    color: #f70c3f;
    margin-bottom: var(--hojayfa-space-xl-1);
    font-size: var(--hojayfa-font-size-2xl-1);
    font-weight: 700;
}

/* ===================================
   COMPONENT: CARD
   =================================== */
.hojayfa-card-1 {
	  border: 3px dashed rgba(239, 68, 68, 0.5);
    border-radius: var(--hojayfa-radius-2xl-1);
    padding: var(--hojayfa-space-lg-1);
}

/* ===================================
   COMPONENT: SLIDER
   =================================== */
.hojayfa-slider-container-1 {
    display: flex;
    align-items: center;
    gap: var(--hojayfa-space-md-1);
}

.hojayfa-slider-1 {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 6px;
    border-radius: var(--hojayfa-radius-sm-1);
    background: var(--hojayfa-color-neutral-200-1);
    outline: none;
    transition: background var(--hojayfa-transition-fast-1);
}

.hojayfa-slider-1::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--hojayfa-color-primary-1);
    cursor: pointer;
    border: 3px solid var(--hojayfa-color-white-1);
    box-shadow: var(--hojayfa-shadow-md-1);
    transition: all var(--hojayfa-transition-fast-1);
}

.hojayfa-slider-1::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--hojayfa-color-primary-1);
    cursor: pointer;
    border: 3px solid var(--hojayfa-color-white-1);
    box-shadow: var(--hojayfa-shadow-md-1);
    transition: all var(--hojayfa-transition-fast-1);
}

.hojayfa-slider-1::-webkit-slider-thumb:hover {
    transform: scale(1.1);
}

.hojayfa-slider-1::-moz-range-thumb:hover {
    transform: scale(1.1);
}

.hojayfa-slider-value-1 {
    min-width: 48px;
    text-align: center;
    font-weight: 500;
    color: var(--hojayfa-color-neutral-700-1);
}

/* ===================================
   COMPONENT: COLOR PICKER
   =================================== */
.hojayfa-color-picker-wrapper-1 {
    display: flex;
    align-items: center;
    gap: var(--hojayfa-space-sm-1);
    flex-wrap: wrap;
}

.hojayfa-color-swatch-1 {
    width: 36px;
    height: 36px;
    border-radius: var(--hojayfa-radius-md-1);
    border: 2px solid var(--hojayfa-color-neutral-300-1);
    cursor: pointer;
    transition: all var(--hojayfa-transition-fast-1);
    position: relative;
}

.hojayfa-color-swatch-1:hover {
    transform: scale(1.1);
    box-shadow: var(--hojayfa-shadow-md-1);
}

.hojayfa-color-swatch-1.hojayfa-active-1 {
    border-color: var(--hojayfa-color-primary-1);
    box-shadow: 0 0 0 3px var(--hojayfa-color-primary-light-1);
}

.hojayfa-color-input-1 {
    width: 60px;
    height: 36px;
    border: 2px solid var(--hojayfa-color-neutral-300-1);
    border-radius: var(--hojayfa-radius-md-1);
    cursor: pointer;
}

/* ===================================
   COMPONENT: TOGGLE SWITCH
   =================================== */
.hojayfa-toggle-switch-1 {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
}

.hojayfa-toggle-switch-1 input {
    opacity: 0;
    width: 0;
    height: 0;
}

.hojayfa-toggle-slider-1 {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: var(--hojayfa-color-neutral-300-1);
    transition: var(--hojayfa-transition-base-1);
    border-radius: 24px;
}

.hojayfa-toggle-slider-1:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: var(--hojayfa-color-white-1);
    transition: var(--hojayfa-transition-base-1);
    border-radius: 50%;
    box-shadow: var(--hojayfa-shadow-sm-1);
}

input:checked + .hojayfa-toggle-slider-1 {
    background-color: var(--hojayfa-color-primary-1);
}

input:checked + .hojayfa-toggle-slider-1:before {
    transform: translateX(24px);
}

/* ===================================
   COMPONENT: BADGE
   =================================== */
.hojayfa-badge-1 {
    display: inline-flex;
    align-items: center;
    gap: var(--hojayfa-space-xs-1);
    padding: 0.25rem 0.625rem;
    font-size: var(--hojayfa-font-size-xs-1);
    font-weight: 500;
    border-radius: var(--hojayfa-radius-md-1);
    line-height: 1;
}

.hojayfa-badge-success-1 {
    background-color: #065f46;
    color: #d1fae5;
}

.hojayfa-badge-error-1 {
    background-color: #991b1b;
    color: #fee2e2;
}

.hojayfa-badge-warning-1 {
    background-color: #92400e;
    color: #fef3c7;
}

.hojayfa-badge-neutral-1 {
    background-color: var(--hojayfa-color-neutral-300-1);
    color: var(--hojayfa-color-neutral-700-1);
}

/* ===================================
   COMPONENT: TOAST
   =================================== */
.hojayfa-toast-container-1 {
    position: fixed;
    top: var(--hojayfa-space-lg-1);
    right: var(--hojayfa-space-lg-1);
    z-index: var(--hojayfa-z-toast-1);
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-md-1);
    max-width: 400px;
}

.hojayfa-toast-1 {
    background-color: var(--hojayfa-color-card-bg-1);
    border-radius: var(--hojayfa-radius-xl-1);
    box-shadow: var(--hojayfa-shadow-lg-1);
    padding: var(--hojayfa-space-lg-1);
    display: flex;
    align-items: start;
    gap: var(--hojayfa-space-md-1);
    border-left: 4px solid;
    animation: hojayfa-slideIn-1 var(--hojayfa-transition-base-1);
}

@keyframes hojayfa-slideIn-1 {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.hojayfa-toast-success-1 {
    border-color: var(--hojayfa-color-success-1);
}

.hojayfa-toast-error-1 {
    border-color: var(--hojayfa-color-error-1);
}

.hojayfa-toast-info-1 {
    border-color: var(--hojayfa-color-primary-1);
}

.hojayfa-toast-content-1 {
    flex: 1;
}

.hojayfa-toast-title-1 {
    font-weight: 600;
    margin-bottom: var(--hojayfa-space-xs-1);
    color: var(--hojayfa-color-neutral-900-1);
}

.hojayfa-toast-message-1 {
    font-size: var(--hojayfa-font-size-sm-1);
    color: var(--hojayfa-color-neutral-600-1);
}

/* ===================================
   LAYOUT
   =================================== */
.hojayfa-container-1 {
    max-width: 1200px;
    margin: 0 auto;
    padding: var(--hojayfa-space-lg-1);
}

.hojayfa-layout-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-lg-1);
    min-height: 100vh;
    padding-bottom: 100px;
}

/* ===================================
   UPLOAD AREA
   =================================== */
.hojayfa-upload-area-1 {
    border-radius: var(--hojayfa-radius-2xl-1);
    padding: var(--hojayfa-space-2xl-1);
    text-align: center;
    cursor: pointer;
    transition: all var(--hojayfa-transition-base-1);
    min-height: 200px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: var(--hojayfa-space-lg-1);
}

.hojayfa-upload-area-1.hojayfa-drag-over-1 {
    border-color: var(--hojayfa-color-primary-1);
    background-color: var(--hojayfa-color-neutral-100-1);
    transform: scale(1.02);
}

.hojayfa-upload-icon-1 {
    width: 64px;
    height: 64px;
    margin: 0 auto;
    color: var(--hojayfa-color-neutral-400-1);
}

.hojayfa-upload-title-1 {
    font-size: var(--hojayfa-font-size-lg-1);
    font-weight: 600;
    color: var(--hojayfa-color-neutral-900-1);
}

.hojayfa-upload-description-1 {
    font-size: var(--hojayfa-font-size-sm-1);
    color: var(--hojayfa-color-neutral-600-1);
}

.hojayfa-upload-formats-1 {
    font-size: var(--hojayfa-font-size-xs-1);
    color: var(--hojayfa-color-neutral-500-1);
    margin-top: var(--hojayfa-space-sm-1);
}

#hojayfaFileInput1 {
    display: none;
}

/* ===================================
   SETTINGS PANEL
   =================================== */
.hojayfa-settings-grid-1 {
    display: grid;
    gap: var(--hojayfa-space-lg-1);
}

.hojayfa-setting-item-1 {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: var(--hojayfa-space-md-1);
    padding: var(--hojayfa-space-md-1);
    border-radius: var(--hojayfa-radius-lg-1);
    background-color: var(--hojayfa-color-neutral-100-1);
}

.hojayfa-setting-info-1 {
    flex: 1;
}

.hojayfa-setting-title-1 {
    font-weight: 600;
    color: var(--hojayfa-color-neutral-900-1);
    margin-bottom: var(--hojayfa-space-xs-1);
}

.hojayfa-setting-description-1 {
    font-size: var(--hojayfa-font-size-sm-1);
    color: var(--hojayfa-color-neutral-600-1);
}

/* ===================================
   IMAGE GALLERY
   =================================== */
.hojayfa-image-gallery-1 {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: var(--hojayfa-space-lg-1);
    margin-top: var(--hojayfa-space-lg-1);
}

.hojayfa-image-card-1 {
    background-color: var(--hojayfa-color-card-bg-1);
    border-radius: var(--hojayfa-radius-xl-1);
    padding: var(--hojayfa-space-md-1);
    border: 1px solid var(--hojayfa-color-neutral-200-1);
    transition: all var(--hojayfa-transition-fast-1);
    display: flex;
    flex-direction: column;
}

.hojayfa-image-card-1:hover {
    box-shadow: var(--hojayfa-shadow-md-1);
    transform: translateY(-2px);
}

.hojayfa-image-preview-container-1 {
    width: 100%;
    aspect-ratio: 4/3;
    border-radius: var(--hojayfa-radius-md-1);
    overflow: hidden;
    background-color: var(--hojayfa-color-neutral-100-1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: var(--hojayfa-space-md-1);
    position: relative;
}

.hojayfa-image-preview-1 {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.hojayfa-image-info-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-sm-1);
}

.hojayfa-image-name-1 {
    font-weight: 500;
    color: var(--hojayfa-color-neutral-900-1);
    word-break: break-word;
    font-size: var(--hojayfa-font-size-sm-1);
}

.hojayfa-image-meta-1 {
    display: flex;
    gap: var(--hojayfa-space-md-1);
    font-size: var(--hojayfa-font-size-xs-1);
    color: var(--hojayfa-color-neutral-600-1);
    flex-wrap: wrap;
}

.hojayfa-image-controls-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-md-1);
    margin-top: var(--hojayfa-space-md-1);
    padding-top: var(--hojayfa-space-md-1);
    border-top: 1px solid var(--hojayfa-color-neutral-200-1);
}

.hojayfa-control-group-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-xs-1);
}

.hojayfa-control-label-1 {
    font-size: var(--hojayfa-font-size-xs-1);
    font-weight: 500;
    color: var(--hojayfa-color-neutral-700-1);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.hojayfa-image-actions-1 {
    display: flex;
    gap: var(--hojayfa-space-sm-1);
    margin-top: var(--hojayfa-space-sm-1);
}

/* ===================================
   PREVIEW PANEL
   =================================== */
.hojayfa-preview-section-1 {
    margin-top: var(--hojayfa-space-lg-1);
}

.hojayfa-preview-grid-1 {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--hojayfa-space-lg-1);
}

@media (min-width: 768px) {
    .hojayfa-preview-grid-1 {
        grid-template-columns: 1fr 1fr;
    }
}

.hojayfa-preview-card-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-md-1);
}

.hojayfa-preview-label-1 {
    font-size: var(--hojayfa-font-size-sm-1);
    font-weight: 600;
    color: var(--hojayfa-color-neutral-700-1);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.hojayfa-preview-image-container-1 {
    border-radius: var(--hojayfa-radius-xl-1);
    overflow: hidden;
    background-color: var(--hojayfa-color-neutral-100-1);
    position: relative;
    aspect-ratio: 16/9;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--hojayfa-color-neutral-200-1);
}

.hojayfa-preview-image-1 {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.hojayfa-preview-info-1 {
    display: flex;
    flex-direction: column;
    gap: var(--hojayfa-space-xs-1);
    font-size: var(--hojayfa-font-size-sm-1);
    color: var(--hojayfa-color-neutral-600-1);
}

.hojayfa-preview-savings-1 {
    display: flex;
    align-items: center;
    gap: var(--hojayfa-space-sm-1);
    padding: var(--hojayfa-space-md-1);
    background: linear-gradient(135deg, #065f46 0%, #047857 100%);
    border-radius: var(--hojayfa-radius-lg-1);
    font-weight: 600;
    color: #d1fae5;
}

/* ===================================
   STICKY TOOLBAR
   =================================== */
.hojayfa-sticky-toolbar-1 {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background-color: var(--hojayfa-color-card-bg-1);
    border-top: 1px solid var(--hojayfa-color-neutral-200-1);
    padding: var(--hojayfa-space-md-1) var(--hojayfa-space-lg-1);
    box-shadow: 0 -4px 6px -1px rgb(0 0 0 / 0.3);
    z-index: var(--hojayfa-z-sticky-1);
}

.hojayfa-toolbar-content-1 {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--hojayfa-space-md-1);
    flex-wrap: wrap;
}

.hojayfa-toolbar-info-1 {
    display: flex;
    align-items: center;
    gap: var(--hojayfa-space-lg-1);
    font-size: var(--hojayfa-font-size-sm-1);
    color: var(--hojayfa-color-neutral-600-1);
}

.hojayfa-toolbar-actions-1 {
    display: flex;
    gap: var(--hojayfa-space-sm-1);
    flex-wrap: wrap;
}

/* ===================================
   EMPTY STATE
   =================================== */
.hojayfa-empty-state-1 {
    text-align: center;
    padding: var(--hojayfa-space-2xl-1);
    color: var(--hojayfa-color-neutral-500-1);
}

.hojayfa-empty-icon-1 {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--hojayfa-space-lg-1);
    opacity: 0.5;
}

/* ===================================
   UTILITY CLASSES
   =================================== */
.hojayfa-hidden-1 {
    display: none !important;
}

.hojayfa-mt-lg-1 {
    margin-top: var(--hojayfa-space-lg-1);
}

.hojayfa-mb-md-1 {
    margin-bottom: var(--hojayfa-space-md-1);
}

/* ===================================
   RESPONSIVE ADJUSTMENTS
   =================================== */
@media (max-width: 640px) {
    .hojayfa-container-1 {
        padding: var(--hojayfa-space-md-1);
    }

    .hojayfa-upload-area-1 {
        padding: var(--hojayfa-space-lg-1);
        min-height: 160px;
    }

    .hojayfa-upload-icon-1 {
        width: 48px;
        height: 48px;
    }

    .hojayfa-upload-title-1 {
        font-size: var(--hojayfa-font-size-base-1);
    }

    .hojayfa-toolbar-content-1 {
        flex-direction: column;
        align-items: stretch;
    }

    .hojayfa-toolbar-info-1 {
        justify-content: center;
        flex-wrap: wrap;
    }

    .hojayfa-toolbar-actions-1 {
        width: 100%;
        flex-direction: column;
    }

    .hojayfa-toolbar-actions-1 .hojayfa-btn-1 {
        width: 100%;
    }

    .hojayfa-toast-container-1 {
        left: var(--hojayfa-space-md-1);
        right: var(--hojayfa-space-md-1);
        max-width: none;
    }

    .hojayfa-image-gallery-1 {
        grid-template-columns: 1fr;
    }

    .hojayfa-app-title-1 {
        font-size: var(--hojayfa-font-size-xl-1);
    }
}

/* ===================================
   ACCESSIBILITY
   =================================== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

*:focus-visible {
    outline: 2px solid var(--hojayfa-color-primary-1);
    outline-offset: 2px;
}

/* ===================================
   LOADING SPINNER
   =================================== */
.hojayfa-spinner-1 {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--hojayfa-color-white-1);
    border-radius: 50%;
    animation: hojayfa-spin-1 0.6s linear infinite;
}

@keyframes hojayfa-spin-1 {
    to { transform: rotate(360deg); }
}