:root{
  --blue:#363d9c;
  --page:#1f2a78;
  --dark:#16009f;
  --yellow:#f7a90a;
  --white:#ffffff;
  --text:#ffffff;
}

*{
  box-sizing:border-box;
}

html{
  scroll-behavior:smooth;
}

body{
  margin:0;
  min-height:100vh;
  font-family:Arial,Helvetica,sans-serif;
  background:var(--page);
  color:var(--text);
}

a{
  color:inherit;
}

.page{
  width:min(100%,900px);
  min-height:100vh;
  margin:0 auto;
  padding:32px 18px;
  display:grid;
  align-items:center;
}

.page--narrow{
  width:min(100%,760px);
}

.card{
  width:100%;
  padding:clamp(28px,6vw,56px);
  border:4px solid rgba(255,255,255,.25);
  border-radius:24px;
  background:var(--blue);
  box-shadow:0 20px 50px rgba(0,0,0,.28);
}

.badge{
  width:76px;
  height:76px;
  margin:0 auto 22px;
  display:grid;
  place-items:center;
  border-radius:50%;
  background:var(--yellow);
  color:var(--dark);
  font-size:46px;
  font-weight:900;
}

h1,
.page-title{
  margin:0 0 18px;
  text-align:center;
  font-size:clamp(3.5rem,8vw,5.6rem);
  line-height:.95;
  font-weight:900;
  color:var(--white);
  text-shadow:
    3px 3px 0 var(--dark),
    -3px 3px 0 var(--dark),
    3px -3px 0 var(--dark),
    -3px -3px 0 var(--dark);
}

.page-title--yellow,
.section-title,
.status{
  color:var(--yellow);
  text-transform:uppercase;
  text-shadow:2px 2px 0 var(--dark);
}

.section-title{
  margin:42px 0 20px;
  font-size:clamp(2rem,5vw,3rem);
  font-weight:900;
}

.status{
  margin:0 0 28px;
  text-align:center;
  font-size:clamp(1.5rem,5vw,2.6rem);
  font-weight:900;
}

.lead,
p{
  margin:0 0 18px;
  font-size:clamp(1.15rem,4vw,1.45rem);
  line-height:1.45;
  font-weight:700;
}

.lead{
  text-align:center;
  margin-bottom:28px;
}

.description{
  margin:0 0 44px;
  text-align:center;
  font-size:clamp(1rem,2vw,2.5rem);
  line-height:1.15;
  font-weight:900;
  text-shadow:3px 3px 0 var(--dark);
}

.dates{
  margin:0 0 44px;
  text-align:center;
  font-size:clamp(1.5rem,3vw,2.5rem);
  line-height:1.15;
  font-weight:900;
  text-shadow:3px 3px 0 var(--dark);
}


.program{
  display:grid;
  gap:12px;
}

.program details{
  border-radius:16px;
  background:rgba(255,255,255,.12);
  overflow:hidden;
}

.program summary{
  display:flex;
  align-items:center;
  gap:14px;
  padding:16px 18px;
  font-size:clamp(1.2rem,3vw,1.75rem);
  font-weight:800;
  cursor:pointer;
  list-style:none;
}

.program summary::-webkit-details-marker{
  display:none;
}

.program summary span{
  width:1.15em;
  height:1.15em;
  display:inline-grid;
  place-items:center;
  flex:0 0 auto;
  border:3px solid var(--white);
  color:var(--white);
  font-size:.9em;
  line-height:1;
}

.program details[open] summary span::after{
  content:"✓";
  font-weight:900;
}

.program p{
  margin:0;
  padding:0 18px 18px calc(18px + 1.15em + 14px);
  font-size:clamp(1rem,2.5vw,1.25rem);
  line-height:1.45;
  font-weight:700;
  opacity:.95;
}

.details{
  margin:26px 0;
}

.details li{
  font-size:clamp(1.05rem,4vw,1.3rem);
  font-weight:800;
}

.details strong{
  color:var(--yellow);
}

.button,
button{
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  min-height:72px;
  margin-top:28px;
  padding:16px 20px;
  border:4px solid var(--dark);
  border-radius:18px;
  background:var(--yellow);
  color:var(--dark);
  text-decoration:none;
  text-transform:uppercase;
  font:inherit;
  font-size:clamp(1.25rem,5vw,2rem);
  font-weight:900;
  cursor:pointer;
}

.button:hover,
button:hover{
  filter:brightness(1.05);
}

.small{
  margin-top:22px;
  font-size:1rem;
  opacity:.9;
  text-align:center;
}

.form{
  display:grid;
  gap:18px;
}

.field{
  display:grid;
  gap:8px;
}

label{
  font-size:1.1rem;
  font-weight:900;
}

input,
select{
  width:100%;
  min-height:58px;
  padding:14px 16px;
  border:3px solid var(--white);
  border-radius:14px;
  background:var(--white);
  color:#111;
  font:inherit;
  font-size:1.1rem;
}

input:focus,
select:focus{
  outline:4px solid var(--yellow);
  outline-offset:2px;
}

@media (max-width:520px){
  .page{
    padding:18px 12px;
  }

  .card{
    padding:26px 18px;
    border-radius:20px;
  }

  .badge{
    width:64px;
    height:64px;
    font-size:38px;
  }

  h1,
  .page-title{
    text-shadow:
      2px 2px 0 var(--dark),
      -2px 2px 0 var(--dark),
      2px -2px 0 var(--dark),
      -2px -2px 0 var(--dark);
  }
}

/* Admin */
.page--wide{
  width:min(100%,1180px);
  align-items:start;
}

.admin-header{
  display:flex;
  justify-content:space-between;
  gap:20px;
  align-items:center;
  margin-bottom:28px;
}

.admin-header .page-title{
  margin:0;
  text-align:left;
  font-size:clamp(2.2rem,5vw,4.2rem);
}

.admin-logout{
  width:auto;
  min-height:48px;
  margin:0;
  padding:10px 18px;
  font-size:1rem;
  border-width:3px;
}

.admin-filter{
  display:grid;
  grid-template-columns:repeat(4,1fr);
  gap:16px;
  align-items:end;
  margin:0 0 28px;
  padding:22px;
  border-radius:20px;
  background:rgba(255,255,255,.10);
}

.admin-filter button{
  margin:0;
  min-height:58px;
  font-size:1.15rem;
}

.table-wrap{
  overflow-x:auto;
  border-radius:0;
  background:rgba(255,255,255,.10);
}

table{
  width:100%;
  border-collapse:collapse;
  color:var(--white);
  font-size:1rem;
}

th,
td{
  padding:13px 14px;
  border-bottom:1px solid rgba(255,255,255,.20);
  text-align:left;
  vertical-align:top;
}

th{
  color:var(--yellow);
  font-weight:900;
  text-transform:uppercase;
  background:rgba(0,0,0,.16);
}

tr:hover td{
  background:rgba(255,255,255,.06);
}

.email-box{
  width:100%;
  min-height:140px;
  margin-top:12px;
  padding:16px;
  border:3px solid rgba(255,255,255,.35);
  border-radius:16px;
  background:rgba(255,255,255,.12);
  color:var(--white);
  font:inherit;
  line-height:1.45;
  resize:vertical;
}

.error{
  margin:0 0 18px;
  padding:14px 16px;
  border-radius:16px;
  background:rgba(247,169,10,.18);
  color:var(--white);
  font-weight:800;
}

@media (max-width:820px){
  .admin-header{
    display:block;
  }

  .admin-logout{
    width:100%;
    margin-top:18px;
  }

  .admin-filter{
    grid-template-columns:1fr;
  }
}

table{
  width:100%;
  border-collapse:collapse;
  border-radius:0;
  overflow:visible;
  background:white;
  color:#111;
}

th,
td{
  padding:12px 14px;
  border:1px solid rgba(0,0,0,.12);
  text-align:left;
}

th{
  background:#f3f4ff;
  color:#16009f;
  font-weight:900;
}

tr:nth-child(even){
  background:#f8f9ff;
}

/* Edit participant – mobile friendly */
.edit-page{
  min-height:100vh;
}

.edit-page .card{
  max-width:760px;
  margin:0 auto;
}

.edit-page input,
.edit-page select,
.edit-page button{
  font-size:1.1rem;
}

@media (max-width:520px){
  .edit-page{
    padding:12px;
    align-items:start;
  }

  .edit-page .card{
    padding:22px 16px;
    border-radius:20px;
  }

  .edit-page .page-title{
    font-size:2.2rem;
    line-height:1;
    margin-bottom:24px;
  }

  .edit-page .form{
    gap:16px;
  }

  .edit-page input,
  .edit-page select{
    min-height:54px;
    padding:13px 14px;
    font-size:1rem;
    border-radius:12px;
  }

  .edit-page label{
    font-size:1rem;
  }

  .edit-page button{
    min-height:62px;
    margin-top:18px;
    font-size:1.35rem;
    border-radius:14px;
  }
}

span,
.yellow{
  color:var(--yellow);
}


/* Admin action icons */
.actions-cell{
  white-space:nowrap;
  text-align:center;
}

.inline-form{
  display:inline;
  margin:0;
  padding:0;
}

.actions-cell{
  white-space:nowrap;
  text-align:center;
}

.icon-button{
  display:inline-block;
  margin:0 4px;
  text-decoration:none;
  font-size:1.2rem;
  font-weight:900;
  line-height:1;
  background:none;
  border:none;
  padding:0;
}

.icon-button-edit{
  color:#16009f;
}

.icon-button-delete{
  color:#c40000;
}

.icon-button:hover{
  opacity:.75;
}

.icon-button:hover{
  filter:brightness(.95);
}

.state-prihlasen{
    color:#16009f;
    font-weight:700;
}

.state-zaplaceno{
    color:#008000;
    font-weight:700;
}

.state-nahradnik{
    color:#d97706;
    font-weight:700;
}

.state-smazan{
    color:#808080;
}
