/* Moderní CSS pro servisní portál menu */
.portal-modern-menu {
    width: 100vw;                /* zabere celou šířku viewportu */
    margin-left: calc(-50vw + 50%);  /* vystředí full-width obsah */
    margin-right: calc(-50vw + 50%);
    padding: 40px 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 0;            /* bez zaoblení okrajů */
    box-shadow: none;            /* nebo slabší stín */
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    position: relative;
}


.portal-modern-menu::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="white" opacity="0.1"/><circle cx="75" cy="75" r="1" fill="white" opacity="0.05"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    pointer-events: none;
}

.menu-container {
    position: relative;
    z-index: 1;
}

.menu-header {
    text-align: center;
    margin-bottom: 40px;
}

.menu-title {
    color: white;
    font-size: 2.5em;
    font-weight: 300;
    margin: 0 0 10px 0;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
}

.menu-title i {
    margin-right: 15px;
    opacity: 0.9;
}

.menu-subtitle {
    color: rgba(255,255,255,0.9);
    font-size: 1.1em;
    margin: 0 0 20px 0;
    font-weight: 300;
}

.user-welcome {
    background: rgba(255,255,255,0.15);
    padding: 10px 20px;
    border-radius: 25px;
    color: white;
    display: inline-block;
    backdrop-filter: blur(10px);
    font-size: 0.95em;
}

.user-welcome i {
    margin-right: 8px;
    opacity: 0.8;
}

.menu-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 40px;
}

.menu-item {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 15px;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    position: relative;
    animation: slideInUp 0.6s ease-out forwards;
    opacity: 0;
    transform: translateY(30px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

@keyframes slideInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-item:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}

.menu-item-inner {
    padding: 30px 25px;
    display: flex;
    align-items: center;
    position: relative;
}

.menu-icon {
    font-size: 2.5em;
    color: #666;
    margin-right: 20px;
    transition: all 0.3s ease;
    min-width: 60px;
    text-align: center;
}

.menu-content {
    flex: 1;
}

.menu-item-title {
    font-size: 1.3em;
    font-weight: 600;
    margin: 0 0 8px 0;
    color: #333;
}

.menu-item-description {
    color: #666;
    margin: 0;
    font-size: 0.95em;
    line-height: 1.4;
}

.menu-arrow {
    font-size: 1.2em;
    color: #ccc;
    transition: all 0.3s ease;
    margin-left: 15px;
}

.menu-item:hover .menu-arrow {
    transform: translateX(8px);
    color: #999;
}

/* Statistiky */
.menu-stats {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 30px;
    padding: 25px;
    background: rgba(255,255,255,0.1);
    border-radius: 15px;
    backdrop-filter: blur(10px);
}

.stat-item {
    text-align: center;
    color: white;
    position: relative;
}

.stat-icon {
    font-size: 1.5em;
    opacity: 0.7;
    margin-bottom: 10px;
}

.stat-number {
    display: block;
    font-size: 2.5em;
    font-weight: 700;
    margin-bottom: 5px;
    text-shadow: 0 2px 10px rgba(0,0,0,0.3);
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.stat-label {
    font-size: 0.9em;
    opacity: 0.9;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Loading spinner */
.loading-spinner {
    width: 30px;
    height: 30px;
    border: 3px solid rgba(255,255,255,0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer */
.menu-footer {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.2);
}

.menu-footer-text {
    color: rgba(255,255,255,0.8);
    font-size: 0.9em;
    margin: 0;
}

.menu-footer-text i {
    margin-right: 8px;
    opacity: 0.7;
}

/* Responzivní design */
@media (max-width: 768px) {
    .portal-modern-menu {
        padding: 30px 15px;
        margin: 10px;
    }
    
    .menu-title {
        font-size: 2em;
    }
    
    .menu-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .menu-item-inner {
        padding: 25px 20px;
    }
    
    .menu-icon {
        font-size: 2em;
        margin-right: 15px;
        min-width: 50px;
    }
    
    .menu-item-title {
        font-size: 1.2em;
    }
    
    .menu-stats {
        flex-direction: column;
        gap: 20px;
    }
    
    .stat-number {
        font-size: 2em;
        min-height: 50px;
    }
}

@media (max-width: 480px) {
    .menu-item-inner {
        flex-direction: column;
        text-align: center;
    }
    
    .menu-icon {
        margin-right: 0;
        margin-bottom: 15px;
    }
    
    .menu-arrow {
        position: absolute;
        top: 20px;
        right: 20px;
        margin: 0;
    }
    
    .menu-stats {
        flex-direction: column;
        gap: 15px;
    }
}

/* Hover efekty pro jednotlivé barvy */
.menu-item[data-color="#4CAF50"]:hover {
    border-color: #4CAF50;
}

.menu-item[data-color="#2196F3"]:hover {
    border-color: #2196F3;
}

.menu-item[data-color="#FF9800"]:hover {
    border-color: #FF9800;
}

.menu-item[data-color="#9C27B0"]:hover {
    border-color: #9C27B0;
}

.menu-item[data-color="#F44336"]:hover {
    border-color: #F44336;
}

.menu-item[data-color="#607D8B"]:hover {
    border-color: #607D8B;
}

/* Accessibility */
.menu-item:focus {
    outline: 3px solid rgba(255,255,255,0.6);
    outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
    .menu-item {
        animation: none;
    }
    
    .menu-item:hover {
        transform: none;
    }
    
    .menu-arrow {
        transition: none;
    }
    
    .menu-item:hover .menu-arrow {
        transform: none;
    }
    
    .loading-spinner {
        animation: none;
    }
}

/* Divi kompatibilita */
.et_pb_section .portal-modern-menu {
    margin: 0;
}

.et_pb_row .portal-modern-menu {
    max-width: none;
}

/*----------------------------------------------------------------------------*/
/* Kontejner pro dynamický obsah */
#dynamic-content-area {
    min-height: 400px;
    padding: 30px;
    margin-top: 30px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Loading spinner */
.loading-spinner {
    text-align: center;
    padding: 50px;
    font-size: 18px;
    color: #666;
}

.loading-spinner i {
    font-size: 32px;
    margin-bottom: 15px;
    display: block;
}

/* Error message */
.error-message {
    padding: 20px;
    background: #fee;
    border: 1px solid #fcc;
    border-radius: 4px;
    color: #c33;
    text-align: center;
}

/* Welcome message */
.welcome-message {
    text-align: center;
    padding: 50px;
    color: #666;
}

/* Menu items jako tlačítka místo odkazů */
.menu-item.dynamic-load {
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.menu-item.dynamic-load:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    text-decoration: none;
}

.menu-item.dynamic-load:active {
    transform: translateY(-2px);
}
