 body {
      height: 100%;
      margin: 0;
      padding-top:5em;
      font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
      /*background-color: #a4cbeb;*/
      background: 
        url('/style/images/logo_bile.png') no-repeat 20px 20px,
        repeating-linear-gradient(
          to right,
          #4baeea 0%,
          #4baeea 40%,
          #61b9ea 40%,
          #61b9ea 60%,
          #78c3eb 60%,
          #78c3eb 80%,
          #8fceec 80%,
          #8fceec 100%
        );
      background-size: auto 5em, cover;
      background-attachment: fixed;
    }

h1 {
    text-align: center;
    margin-bottom: 20px;
    color: #111827;
}

.controls {
    text-align: center;
    margin-bottom: 20px;
    padding: 0 10px;
}

select {
    padding: 8px 12px;
    font-size: 1em;
    border-radius: 8px;
    border: 1px solid #ccc;
    margin-top: 10px;
}

.container,
#app-list,
#history-list {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    justify-content: center;
    transition: opacity 0.3s ease-out;
}

.fade {
    opacity: 0;
}

.visible {
    opacity: 1;
}

/* Karty */
.card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    padding: 16px;
    width: 100%;
    max-width: 400px;
    box-sizing: border-box;
}

.card.active {
    border: 2px solid #10b981;
    background-color: #ecfdf5;
}

.title {
    font-size: 1.1em;
    font-weight: bold;
    color: #1f2937;
    word-wrap: break-word;
}

.subtitle {
    font-size: 0.95em;
    color: #6b7280;
    margin-top: 4px;
}

.meta {
    font-size: 0.85em;
    color: #9ca3af;
    margin-top: 8px;
}

.tabs {
    display: flex;
    justify-content: center;
    gap: 12px;
    margin: 20px 0;
    flex-wrap: wrap;
}

.tab-button {
    padding: 8px 16px;
    border: none;
    background-color: #e5e7eb;
    border-radius: 6px;
    cursor: pointer;
    font-weight: bold;
    color: #374151;
    transition: background-color 0.2s;
}

.tab-button.active {
    background-color: #2563eb;
    color: white;
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 15px;
    padding: 10px 0;
}

.page-button {
    margin: 0 2px;
    padding: 4px 10px;
    border: none;
    background: #e5e7eb;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}

.page-button.active {
    background-color: #2563eb;
    color: white;
}

#pagination {
    margin-top: 15px;
    text-align: center;
}

.title a {
    color: #111827;
    text-decoration: none;
    transition: color 0.2s;
}

.title a:hover {
    color: #2563eb;
    text-decoration: underline;
}

.date-divider {
    width: 100%;
    text-align: center;
    margin: 30px 0 10px;
    font-weight: bold;
    color: #6b7280;
    font-size: 0.9em;
}

/* RESPONSIVITA */
@media (max-width: 768px) {
    .card {
        width: 100% !important;
        box-sizing: border-box;
        flex: unset !important;
        min-width: unset !important;
    }

    .tabs {
        flex-direction: column;
        align-items: center;
    }

    .controls {
        display: block;
        text-align: center;
    }

    html, body {
        touch-action: manipulation;
    }

    input, select, textarea {
        touch-action: manipulation;
    }
}
