* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background: #f5f5f5;
    color: #333;
}

.container {
    display: flex;
    height: 100vh;
}

/* Ľavý panel */
.sidebar {
    width: 350px;
    background: #fff;
    border-right: 1px solid #ddd;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.sidebar h1 {
    padding: 20px;
    background: #4CAF50;
    color: white;
    text-align: center;
    font-size: 1.8em;
}

.sidebar-header {
    padding: 15px;
    background: #f5e6d3;
    text-align: center;
    cursor: pointer;
    transition: background 0.2s;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

.sidebar-header:hover {
    background: #ead7c0;
}

.sidebar-logo {
    max-width: 200px;
    width: 100%;
    height: auto;
}

/* Tlačidlo späť v sidebar-header */
.back-button {
    padding: 8px 16px;
    background: #4CAF50;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.95em;
    transition: background 0.2s;
    align-self: flex-start;
    margin-left: 10px;
}

.back-button:hover {
    background: #45a049;
}

/* Filter tagov */
.filters {
    padding: 15px 20px;
    border-bottom: 1px solid #eee;
}

.filters h3 {
    margin-bottom: 10px;
    font-size: 1em;
    color: #666;
}

#tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag-filter {
    padding: 6px 12px;
    background: #e0e0e0;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    font-size: 0.85em;
    transition: all 0.2s;
}

.tag-filter:hover {
    background: #d0d0d0;
}

.tag-filter.active {
    background: #4CAF50;
    color: white;
}

/* Vyhľadávanie */
.search-wrapper {
    padding: 15px 20px 0 20px;
}

#search-input {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 0.95em;
}

/* Zoznam receptov */
.recipes-list {
    flex: 1;
    overflow-y: visible;
    padding: 15px 20px;
}

#recipes-menu {
    list-style: none;
}

#recipes-menu li {
    padding: 12px 15px;
    margin-bottom: 8px;
    background: #f9f9f9;
    border-radius: 5px;
    cursor: pointer;
    transition: all 0.2s;
    border-left: 3px solid transparent;
}

#recipes-menu li:hover {
    background: #e8f5e9;
    border-left-color: #4CAF50;
}

#recipes-menu li.active {
    background: #e8f5e9;
    border-left-color: #4CAF50;
    font-weight: bold;
}

#recipes-menu li.hidden {
    display: none;
}

/* Hlavná časť */
.content {
    flex: 1;
    padding: 40px;
    overflow-y: auto;
    background: #fafafa;
    position: relative;
}

.welcome {
    text-align: center;
    margin-top: 100px;
    color: #999;
}

.welcome-logo {
    max-width: 800px;
    width: 100%;
    height: auto;
    margin-bottom: 30px;
    border-radius: 8px;
    mix-blend-mode: multiply;
}

#recipe-detail h2 {
    color: #4CAF50;
    margin-bottom: 15px;
    font-size: 2em;
}

.recipe-tags {
    margin: 15px 0;
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.recipe-tag {
    padding: 5px 12px;
    background: #4CAF50;
    color: white;
    border-radius: 15px;
    font-size: 0.85em;
}

/* Info sekcia s ikonami */
.recipe-info {
    margin: 20px 0;
    padding: 15px 20px;
    background: #eeeeee;
    border-radius: 8px;
}

.info-items {
    display: flex !important;
    flex-direction: row !important;
    gap: 40px;
    align-items: center;
    justify-content: flex-start;
    flex-wrap: nowrap;
}

.info-item {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 8px;
    font-size: 1em;
    color: #555;
    white-space: nowrap;
}

.info-item .icon {
    font-size: 1.4em;
    color: #888;
    display: inline-block;
}

/* Dvoj-stĺpcový layout pre obsah receptu */
.recipe-content {
    display: flex;
    gap: 0;
    margin-top: 30px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
}

.ingredients-column {
    flex: 1;
    padding: 25px;
}

.divider {
    width: 2px;
    background: #4CAF50;
    align-self: stretch;
    margin: 20px 0;
}

.instructions-column {
    flex: 2;
    padding: 25px;
}

.ingredients-column h3,
.instructions-column h3 {
    color: #4CAF50;
    margin-bottom: 15px;
    font-size: 1.4em;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 8px;
}

.ingredients-column pre,
.instructions-column pre {
    line-height: 1.8;
    white-space: pre-wrap;
    font-family: inherit;
}

.recipe-section {
    margin-top: 30px;
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.recipe-section h3 {
    color: #4CAF50;
    margin-bottom: 15px;
    font-size: 1.4em;
    border-bottom: 2px solid #4CAF50;
    padding-bottom: 8px;
}

.recipe-section p,
.recipe-section pre {
    line-height: 1.8;
    white-space: pre-wrap;
    font-family: inherit;
}

/* Scrollbar styling */
.sidebar::-webkit-scrollbar,
.recipes-list::-webkit-scrollbar,
.content::-webkit-scrollbar {
    width: 8px;
}

.sidebar::-webkit-scrollbar-track,
.recipes-list::-webkit-scrollbar-track,
.content::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.sidebar::-webkit-scrollbar-thumb,
.recipes-list::-webkit-scrollbar-thumb,
.content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb:hover,
.recipes-list::-webkit-scrollbar-thumb:hover,
.content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Responsive */
@media (max-width: 1024px) {
    .container {
        flex-direction: column;
        overflow-y: auto;
        height: 100vh;
    }
    
    .sidebar {
        width: 100%;
        height: auto;
        max-height: none;
        overflow-y: visible;
        flex-shrink: 0;
    }
    
    .content {
        padding: 20px;
        flex: 1;
        overflow-y: visible;
    }
    
    /* Pri zobrazení receptu schovať len obsah sidebaru, nie logo */
    .sidebar.hidden {
        width: auto;
    }
    
    .sidebar.hidden .search-wrapper,
    .sidebar.hidden .filters,
    .sidebar.hidden .recipes-list {
        display: none;
    }
    
    /* Content skrytý na mobile, zobrazí sa len pri zobrazení receptu */
    .content {
        display: none;
    }
    
    .content.show {
        display: block;
    }
    
    /* Welcome obrazovka bez obrázka */
    .welcome-logo {
        display: none;
    }
    
    .welcome {
        margin-top: 50px;
    }
    
    .recipe-content {
        flex-direction: column;
    }
    
    .divider {
        display: none;
    }
    
    .ingredients-column,
    .instructions-column {
        flex: 1;
    }
    
    /* Info items vertikálne na mobile */
    .info-items {
        flex-direction: column !important;
        align-items: flex-start !important;
        gap: 15px;
    }
    
    .info-item {
        gap: 8px;
        margin: 0;
        padding: 0;
    }
    
    .info-item .icon {
        margin: 0;
        padding: 0;
        width: 1.4em;
        text-align: center;
    }
}
