/* Board list */
.boards-page {
    max-width: 960px;
    margin: 0 auto;
    padding: 1.5rem;
}

.boards-page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.boards-page-header h1 {
    margin: 0;
    font-size: 1.5rem;
}

.boards-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.boards-list-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1rem 1.25rem;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0.5rem;
}

.boards-list-main {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem 0.75rem;
}

.boards-list-name {
    font-size: 1.1rem;
}

.boards-list-meta {
    color: var(--bs-secondary-color);
    font-size: 0.9rem;
}

.boards-list-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.boards-type-badge {
    display: inline-block;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.boards-type-takt {
    background: rgba(13, 110, 253, 0.12);
    color: #0d6efd;
}

.boards-type-pal {
    background: rgba(25, 135, 84, 0.12);
    color: #198754;
}

.boards-empty {
    color: var(--bs-secondary-color);
}

/* Board dashboard (wall) */
.board-dashboard {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.board-dashboard-topbar {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.75rem 1.25rem;
    background: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.board-dashboard-title-wrap {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    min-width: 0;
}

.board-dashboard-title {
    margin: 0;
    font-size: clamp(1.1rem, 2.5vw, 1.5rem);
}

.board-dashboard-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.5rem;
}

.board-select {
    min-width: min(220px, 100%);
    min-height: 44px;
}

.board-dashboard-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    padding: 2rem;
    text-align: center;
}

.board-tiles {
    flex: 1;
    overflow: auto;
    padding: 1rem;
    display: grid;
    gap: 1rem;
    align-content: start;
    -webkit-overflow-scrolling: touch;
}

.board-tiles-takt {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 520px), 1fr));
}

.board-tiles-pal {
    grid-template-columns: repeat(auto-fit, minmax(min(100%, 400px), 1fr));
}

.board-tile {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 0.5rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    min-height: 200px;
}

.board-tile-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.03);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.board-tile-title {
    margin: 0;
    font-size: 1rem;
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.board-tile-gantt {
    flex: 1;
    overflow: auto;
    max-height: min(55vh, 480px);
}

.board-tile-gantt .gantt-layout {
    min-height: 120px;
}

/* Board edit */
.boards-edit-page {
    max-width: 720px;
    margin: 0 auto;
    padding: 1.5rem;
}

.boards-edit-header {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.boards-edit-header h1 {
    margin: 0;
    font-size: 1.35rem;
}

.boards-edit-header-actions {
    display: flex;
    gap: 0.5rem;
}

.boards-edit-form,
.boards-edit-plans {
    padding: 1.25rem;
    margin-bottom: 1rem;
    background: #fff;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 0.5rem;
}

.boards-edit-plans h2 {
    font-size: 1.1rem;
    margin: 0 0 1rem;
}

.boards-assigned-list {
    list-style: none;
    padding: 0;
    margin: 0 0 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.boards-assigned-item {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    padding: 0.5rem 0.75rem;
    background: rgba(0, 0, 0, 0.02);
    border-radius: 0.375rem;
}

.boards-assigned-main {
    flex: 1;
    min-width: 200px;
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.boards-assigned-plan-name {
    font-size: 0.85rem;
    color: var(--bs-secondary-color);
}

.boards-assigned-actions {
    display: flex;
    gap: 0.25rem;
}

.boards-add-plan-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.boards-add-plan-row .form-select {
    flex: 1;
    min-width: 200px;
}

.boards-edit-status {
    margin-left: 0.75rem;
    color: var(--bs-success);
    font-size: 0.9rem;
}
