/* Saha sahibi paneli: yönetim panelinin tasarım sistemi (/admin/admin.css) + haftalık takvim. */

.cal-bar { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; margin-bottom: .9rem; }
.cal-bar .week-label { font-family: var(--f-display); font-weight: 800; font-size: 1.15rem; text-transform: uppercase; min-width: 11ch; text-align: center; }
.legend-row { display: flex; flex-wrap: wrap; gap: .4rem 1rem; font-size: .8rem; color: var(--muted); margin: .2rem 0 .9rem; }
.legend-row i { display: inline-block; width: 14px; height: 14px; border-radius: 4px; margin-right: .35rem; vertical-align: -2px; border-width: 1.5px; border-style: solid; }
.legend-row i.cell--blocked { background-size: auto; }

.cal { overflow: auto; border: 1px solid var(--line); border-radius: var(--r); background: var(--surface); box-shadow: var(--shadow); max-height: calc(100dvh - 15rem); min-height: 240px; }
.cal table { border-collapse: separate; border-spacing: 0; width: 100%; min-width: 780px; table-layout: fixed; }
.cal th { position: sticky; top: 0; z-index: 3; background: var(--surface-2); padding: .55rem .4rem; border-bottom: 1px solid var(--line); font-weight: 700; font-size: .82rem; text-align: center; }
.cal th small { display: block; font-family: var(--f-mono); font-weight: 500; font-size: .66rem; color: var(--muted); letter-spacing: .06em; }
.cal th.today { background: var(--turf-soft); color: var(--turf-d); }
html[data-theme='dark'] .cal th.today { color: var(--turf); }
.cal td { padding: 3px; vertical-align: top; border-bottom: 1px solid var(--line); border-right: 1px solid var(--line); }
.cal td:last-child { border-right: 0; }
.cal th.time, .cal td.time { position: sticky; left: 0; z-index: 2; width: 64px; background: var(--surface-2); text-align: center; font-family: var(--f-mono); font-size: .74rem; color: var(--muted); border-right: 1px solid var(--line-2); }
.cal th.time { z-index: 4; }
.cal td.empty { background: repeating-linear-gradient(135deg, transparent 0 6px, var(--line) 6px 7px); opacity: .5; }

.cell {
  display: flex; flex-direction: column; justify-content: center; gap: .1rem; width: 100%; min-height: 52px; padding: .3rem .45rem; text-align: left;
  border-radius: 8px; border: 1.5px solid transparent; background: var(--surface-2); font-size: .76rem; line-height: 1.25; overflow: hidden; transition: transform .1s, box-shadow .15s;
}
.cell:hover { transform: translateY(-1px); box-shadow: var(--shadow); }
.cell b { font-weight: 700; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cell span { color: inherit; opacity: .75; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cell--available { background: var(--turf-soft); border-color: color-mix(in srgb, var(--turf) 45%, transparent); }
.cell--app { background: var(--info-soft); border-color: color-mix(in srgb, var(--info) 55%, transparent); }
.cell--manual { background: var(--warn-soft); border-color: color-mix(in srgb, var(--warn) 55%, transparent); }
.cell--sub { background: color-mix(in srgb, var(--violet) 14%, transparent); border-color: color-mix(in srgb, var(--violet) 55%, transparent); }
.cell--blocked { background: repeating-linear-gradient(135deg, var(--surface-2) 0 6px, var(--line) 6px 12px); border-color: var(--line-2); color: var(--muted); }
.cell--past { opacity: .55; }
.cell .tag { display: inline-block; align-self: flex-start; padding: 0 .35rem; border-radius: 99px; font-size: .66rem; font-weight: 800; background: var(--flare); color: #1a0a02; }

.dayrow { display: grid; grid-template-columns: 28px 1fr 1fr; gap: .5rem; align-items: center; margin-bottom: .4rem; }
.dayrow label.day { font-weight: 700; display: flex; align-items: center; gap: .5rem; grid-column: 1 / 2; }
.dayrow .name { font-weight: 700; }
.week-hours { display: grid; gap: .35rem; }
.week-hours .row-h { display: grid; grid-template-columns: 7.5rem 1fr 1fr; gap: .5rem; align-items: center; }
.slot-facts { display: grid; gap: .3rem; margin-bottom: .8rem; }
.slot-facts div { display: flex; justify-content: space-between; gap: 1rem; padding: .35rem .6rem; border-radius: 8px; background: var(--surface-2); font-size: .9rem; }
.slot-facts span { color: var(--muted); }
.action-grid { display: grid; gap: .5rem; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); }
.thumbs { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: .5rem; margin-top: .5rem; }
.thumbs img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 8px; display: block; background: var(--surface-2); }
.venue-card--big { display: grid; grid-template-columns: 140px 1fr auto; gap: 1rem; align-items: center; padding: 1rem; }
.venue-card--big img { width: 140px; height: 96px; object-fit: cover; border-radius: 10px; background: var(--surface-2); }
.venue-card--big .ph { width: 140px; height: 96px; border-radius: 10px; display: grid; place-items: center; background: var(--surface-2); color: var(--muted); font-size: .8rem; }
@media (max-width: 640px) {
  .venue-card--big { grid-template-columns: 1fr; }
  .venue-card--big img, .venue-card--big .ph { width: 100%; height: 150px; }
  .cal { max-height: none; }
}
