/* 🚀 HATÁROZAT DRIVE - 2030 HYPERMODERN STYLE 🚀 */

/* === GLOBAL VARIABLES === */
:root {
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --secondary-gradient: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --success-gradient: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --glass-bg: rgba(255, 255, 255, 0.25);
    --glass-border: rgba(255, 255, 255, 0.18);
    --shadow-soft: 0 8px 32px rgba(31, 38, 135, 0.37);
    --shadow-hover: 0 15px 35px rgba(31, 38, 135, 0.5);
    --text-primary: #2d3748;
    --text-secondary: #718096;
    --border-radius: 16px;
    --transition-smooth: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
    --transition-bounce: all 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

/* === MAIN CONTAINER === */
.hatarozat-drive-container {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
    max-width: 100%;
    margin: 0 0 0 20px; /* Bal margó hozzáadva */
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    position: relative;
    transition: var(--transition-smooth);
}

/* === IFRAME STYLES === */
.hatarozat-drive-iframe-wrapper {
    margin-left: 20px; /* Iframe wrapper bal margó */
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    background: white;
}

.hatarozat-drive-iframe-wrapper iframe {
    width: 100%;
    height: 600px;
    border: none;
    display: block;
}

.hatarozat-drive-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--primary-gradient);
    z-index: 1;
}

.hatarozat-drive-container:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
}

/* === BACK BUTTON === */
.hatarozat-drive-back {
    padding: 20px 24px 16px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.1) 0%, rgba(255, 255, 255, 0.05) 100%);
}

.hatarozat-drive-back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 20px;
    background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%);
    color: #ffffff !important;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(24, 27, 42, 0.3);
}

/* Removed ::before pseudo-element to avoid color conflicts */

.hatarozat-drive-back-link:hover {
    transform: translateX(4px) scale(1.02);
    color: #ffffff !important;
    background: linear-gradient(135deg, #2A2D3A 0%, #3A3D4A 100%);
    box-shadow: 0 8px 25px rgba(24, 27, 42, 0.5);
}

/* Removed hover ::before pseudo-element */

/* === FOLDERS SECTION === */
.hatarozat-drive-folders {
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

/* === FILES SECTION === */
.hatarozat-drive-files {
    padding: 8px 0;
}

/* === ITEM STYLES === */
.hatarozat-drive-folder,
.hatarozat-drive-file {
    margin: 0 0 8px 20px; /* Bal margó hozzáadva */
    padding: 0;
    border-radius: 12px;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
}

.hatarozat-drive-folder::before,
.hatarozat-drive-file::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--glass-bg);
    opacity: 0;
    transition: var(--transition-smooth);
    z-index: 0;
}

.hatarozat-drive-folder:hover,
.hatarozat-drive-file:hover {
    transform: translateX(8px) scale(1.01);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
}

.hatarozat-drive-folder:hover::before,
.hatarozat-drive-file:hover::before {
    opacity: 1;
}

/* === FOLDER LINK === */
.hatarozat-drive-folder-link {
    text-decoration: none;
    color: inherit;
    display: block;
    transition: var(--transition-smooth);
    position: relative;
    z-index: 1;
}

.hatarozat-drive-folder-link:hover {
    text-decoration: none;
    color: inherit;
}

/* === ITEM HEADER === */
.hatarozat-drive-item-header {
    display: flex;
    align-items: center;
    padding: 16px 24px;
    cursor: pointer;
    position: relative;
    z-index: 1;
    transition: var(--transition-smooth);
}

.hatarozat-drive-folder .hatarozat-drive-item-header {
    cursor: pointer;
}

.hatarozat-drive-file .hatarozat-drive-item-header {
    cursor: default;
}

/* === MODERN ICONS === */
.hatarozat-drive-icon {
    width: 32px;
    height: 32px;
    margin-right: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: var(--transition-bounce);
    position: relative;
    overflow: hidden;
}

.hatarozat-drive-icon::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--primary-gradient);
    opacity: 0;
    transition: var(--transition-smooth);
    border-radius: 8px;
}

.hatarozat-drive-folder:hover .hatarozat-drive-icon::before {
    opacity: 0.1;
}

.hatarozat-drive-file:hover .hatarozat-drive-icon::before {
    opacity: 0.1;
}

/* Modern Folder Icon - 3D Style */
.folder-icon-modern {
    width: 40px;
    height: 32px;
    position: relative;
    display: inline-block;
    transition: var(--transition-bounce);
}

.folder-icon-modern::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 32px;
    height: 24px;
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    border-radius: 4px 4px 0 0;
    box-shadow: 
        0 2px 4px rgba(0, 0, 0, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    transform: perspective(20px) rotateX(10deg);
}

.folder-icon-modern::after {
    content: '';
    position: absolute;
    top: 8px;
    left: 0;
    width: 32px;
    height: 20px;
    background: linear-gradient(135deg, #ffd700 0%, #ffed4e 100%);
    border-radius: 0 0 4px 4px;
    box-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    transform: perspective(20px) rotateX(-5deg);
}

.hatarozat-drive-folder:hover .folder-icon-modern {
    transform: scale(1.1) rotate(2deg);
}

.hatarozat-drive-folder:hover .folder-icon-modern::before {
    background: linear-gradient(135deg, #ffed4e 0%, #ffd700 100%);
    box-shadow: 
        0 4px 8px rgba(0, 0, 0, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.4);
}

.hatarozat-drive-folder:hover .folder-icon-modern::after {
    background: linear-gradient(135deg, #ffed4e 0%, #ffd700 100%);
    box-shadow: 
        0 6px 12px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
}

/* File Icons - Dynamic Colors */
.file-icon {
    font-size: 20px;
    transition: var(--transition-smooth);
}

.hatarozat-drive-file:hover .file-icon {
    transform: scale(1.1);
}

/* === ITEM NAME === */
.hatarozat-drive-name {
    flex: 1;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    line-height: 1.4;
    transition: var(--transition-smooth);
    word-break: break-word;
}

.hatarozat-drive-folder:hover .hatarozat-drive-name {
    color: #667eea;
    transform: translateX(4px);
}

/* === ACTIONS === */
.hatarozat-drive-actions {
    display: flex;
    gap: 8px;
    margin-left: 16px;
    opacity: 1;
    transform: translateX(0);
    transition: var(--transition-smooth);
}

.hatarozat-drive-view,
.hatarozat-drive-download {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%);
    color: #ffffff !important;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    transition: var(--transition-smooth);
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(24, 27, 42, 0.3);
}

/* Removed ::before pseudo-elements to avoid color conflicts */

.hatarozat-drive-view:hover,
.hatarozat-drive-download:hover {
    transform: translateY(-2px) scale(1.05);
    color: #ffffff !important;
    background: linear-gradient(135deg, #2A2D3A 0%, #3A3D4A 100%);
    box-shadow: 0 8px 25px rgba(24, 27, 42, 0.5);
}

/* Removed hover ::before pseudo-elements */

/* === LOADING STATES === */
.hatarozat-drive-loading {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
    font-size: 16px;
    font-weight: 500;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    margin: 20px;
    position: relative;
    overflow: hidden;
}

.hatarozat-drive-loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--primary-gradient);
    opacity: 0.1;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}

.hatarozat-drive-loading::after {
    content: '⚡';
    display: block;
    font-size: 32px;
    margin-bottom: 16px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.1); opacity: 0.8; }
}

/* === ERROR STATES === */
.hatarozat-drive-error {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a52 100%);
    color: white;
    padding: 20px;
    border-radius: 12px;
    margin: 20px;
    font-weight: 600;
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.3);
    position: relative;
    overflow: hidden;
}

.hatarozat-drive-error::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    animation: shimmer 2s infinite;
}

/* === EMPTY STATE === */
.hatarozat-drive-empty {
    text-align: center;
    padding: 40px 20px;
    color: var(--text-secondary);
    font-style: italic;
    font-size: 16px;
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    margin: 20px;
    border: 1px solid var(--glass-border);
    box-shadow: var(--shadow-soft);
}

/* === RESPONSIVE DESIGN === */
@media (max-width: 768px) {
    .hatarozat-drive-item-header {
        padding: 12px 16px;
    }
    
    .hatarozat-drive-icon {
        width: 28px;
        height: 28px;
        margin-right: 12px;
    }
    
    .hatarozat-drive-name {
        font-size: 14px;
        color: #000000 !important; /* Fekete szöveg mobilra */
    }
    
    .hatarozat-drive-actions {
        flex-direction: column;
        gap: 6px;
        margin-left: 8px;
    }
    
    .hatarozat-drive-view,
    .hatarozat-drive-download {
        font-size: 11px;
        padding: 6px 12px;
        color: #ffffff !important; /* Fehér szöveg mobilra */
        background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%) !important;
    }
    
    .hatarozat-drive-back-link {
        color: #ffffff !important; /* Fehér szöveg mobilra */
        background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%) !important;
    }
    
    .hatarozat-drive-folder:hover,
    .hatarozat-drive-file:hover {
        transform: translateX(4px) scale(1.005);
    }
}

@media (max-width: 480px) {
    .hatarozat-drive-container {
        margin: 0;
        border-radius: 12px;
    }
    
    .hatarozat-drive-back {
        padding: 16px 20px 12px;
    }
    
    .hatarozat-drive-back-link {
        padding: 10px 16px;
        font-size: 13px;
        color: #ffffff !important; /* Fehér szöveg kis képernyőre */
        background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%) !important;
    }
    
    .hatarozat-drive-name {
        color: #000000 !important; /* Fekete szöveg kis képernyőre */
    }
    
    .hatarozat-drive-view,
    .hatarozat-drive-download {
        color: #ffffff !important; /* Fehér szöveg kis képernyőre */
        background: linear-gradient(135deg, #181B2A 0%, #2A2D3A 100%) !important;
    }
}

/* === ADVANCED ANIMATIONS === */
@keyframes slideInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.hatarozat-drive-folder,
.hatarozat-drive-file {
    animation: slideInUp 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.hatarozat-drive-folder:nth-child(1) { animation-delay: 0.1s; }
.hatarozat-drive-folder:nth-child(2) { animation-delay: 0.2s; }
.hatarozat-drive-folder:nth-child(3) { animation-delay: 0.3s; }
.hatarozat-drive-folder:nth-child(4) { animation-delay: 0.4s; }
.hatarozat-drive-folder:nth-child(5) { animation-delay: 0.5s; }

.hatarozat-drive-file:nth-child(1) { animation-delay: 0.1s; }
.hatarozat-drive-file:nth-child(2) { animation-delay: 0.2s; }
.hatarozat-drive-file:nth-child(3) { animation-delay: 0.3s; }
.hatarozat-drive-file:nth-child(4) { animation-delay: 0.4s; }
.hatarozat-drive-file:nth-child(5) { animation-delay: 0.5s; }

/* === GLASS MORPHISM EFFECTS === */
.hatarozat-drive-container {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* === MICRO-INTERACTIONS === */
.hatarozat-drive-folder-link:active {
    transform: scale(0.98);
}

.hatarozat-drive-view:active,
.hatarozat-drive-download:active {
    transform: scale(0.95);
}

/* === MODERN ICONS === */
.icon-eye {
    display: inline-block;
    width: 16px;
    height: 16px;
    background: currentColor;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 4.5C7 4.5 2.73 7.61 1 12c1.73 4.39 6 7.5 11 7.5s9.27-3.11 11-7.5c-1.73-4.39-6-7.5-11-7.5zM12 17c-2.76 0-5-2.24-5-5s2.24-5 5-5 5 2.24 5 5-2.24 5-5 5zm0-8c-1.66 0-3 1.34-3 3s1.34 3 3 3 3-1.34 3-3-1.34-3-3-3z'/%3E%3C/svg%3E") no-repeat center;
    mask-size: contain;
}

.icon-download {
    display: inline-block;
    width: 16px;
    height: 16px;
    background: currentColor;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M19 9h-4V3H9v6H5l7 7 7-7zM5 18v2h14v-2H5z'/%3E%3C/svg%3E") no-repeat center;
    mask-size: contain;
}

/* === ACCESSIBILITY === */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* === DARK MODE SUPPORT === */
@media (prefers-color-scheme: dark) {
    :root {
        --text-primary: #f7fafc;
        --text-secondary: #a0aec0;
        --glass-bg: rgba(0, 0, 0, 0.25);
        --glass-border: rgba(255, 255, 255, 0.1);
    }
}