.reseat-wrapper {
    padding: 16px;
    font-family: Arial, sans-serif;
}

.reseat-title {
    text-align: center;
    margin-bottom: 20px;
}

.reseat-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.reseat-card {
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 6px 16px rgba(0,0,0,0.08);
    cursor: pointer;
    transition: 0.2s;
}

.reseat-card:active {
    transform: scale(0.97);
}

#reseat-tables {
    margin-top: 20px;
}

/* TABLE GRID */
.reseat-tables {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.table {
    padding: 16px;
    border-radius: 12px;
    text-align: center;
    background: #eee;
}

.table.free { background: #22c55e; color: white; }
.table.partial { background: #f59e0b; color: white; }
.table.full { background: #ef4444; color: white; }


.reseat-seat-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 10px;
    margin-top: 20px;
}

.seat {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 12px;
}

.seat.free { background: #22c55e; }
.seat.reserved { background: #f59e0b; }
.seat.occupied { background: #ef4444; }

.reseat-sections {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    margin-top: 20px;
}

.reseat-section {
    padding: 20px;
    background: #fff;
    border-radius: 14px;
    text-align: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.08);
    font-weight: bold;
}

.reseat-section:active {
    transform: scale(0.97);
}

#reseat-output {
    margin-top: 20px;
}

.reseat-tables {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

.reseat-table {
    padding: 16px;
    border-radius: 12px;
    text-align: center;
    color: white;
    cursor: pointer;
}

.reseat-table.free { background: #22c55e; }
.reseat-table.full { background: #ef4444; }
.reseat-table.partial { background: #f59e0b; }

.table-circle {
    position: relative;
    width: 320px;
    height: 320px;
    margin: 40px auto;
}

/* centar */
.table-center {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 90px;
    height: 90px;
    transform: translate(-50%, -50%);
    background: #333;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* KLJUČNO */
.table-circle .seat {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #22c55e;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;

    transform-origin: 0 0;

    transform:
        rotate(calc(var(--i) * 36deg))
        translate(120px)
        rotate(calc(var(--i) * -36deg));
}
