:root{
    --bg:#0f0f10;
    --card-bg:#111;
    --accent:#29d07f;
}

/* General */
body{
    margin:0;
    font-family:Inter,system-ui,Arial;
    background:var(--bg);
    color:#eee;
}
.container{
    max-width:1200px;
    margin:32px auto;
    padding:0 20px;
}

/* Category sections */
.category {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin:36px 0;
    padding:12px 0;
}
.category h2 {
    margin:6px 0 18px;
    font-weight:600;
    font-size:26px;
    color:#fff;
}

/* Card grid */
.grid {
    display:flex;
    flex-wrap:wrap;
    gap:20px;
}

/* Cards */
.cardWrapper {
  display: flex;
  flex-direction: column;
}

.card {
    width:300px;
    height:170px;
    border-radius:12px;
    overflow:hidden;
    position:relative;
    background:var(--card-bg);
    box-shadow:0 6px 18px rgba(0,0,0,0.6);
    cursor:pointer;
    border:3px solid transparent;
    transition:transform .14s,box-shadow .14s,border-color .12s;
}
.card img{
    width:100%;
    height:100%;
    object-fit:cover;
    display:block;
}
.card:hover{
    transform:translateY(-4px);
}

/* Hover overlay */
.card .overlay{
    position:absolute;
    inset:0;
    background:linear-gradient(180deg,rgba(0,0,0,0) 40%,rgba(0,0,0,0.6));
    display:flex;
    align-items:center;
    justify-content:center;
    opacity:0;
    transition:opacity .14s;
    font-weight:600;
}
.card:hover .overlay{
    opacity:1;
}
.overlay .voteText{
    background:rgba(0,0,0,0.6);
    padding:10px 18px;
    border-radius:999px;
}


/* Text inside card */
.card .meta{
    position:absolute;
    left:12px;
    right:12px;
    bottom:12px;
    color:#fff;
    text-shadow:0 2px 6px rgba(0,0,0,0.6);
    font-size:15px;
}

/* Selected card */
.card.selected{
    border-color:var(--accent);
    box-shadow:0 10px 30px rgba(41,208,127,0.12);
}

/* Footer submit button */
.footerBar{
    position:fixed;
    left:0;
    right:0;
    bottom:14px;
    display:flex;
    justify-content:center;
    pointer-events:none;
}
.btn{
    pointer-events:auto;
    background:var(--accent);
    color:#022;
    border:none;
    padding:12px 20px;
    border-radius:8px;
    font-weight:700;
    cursor:pointer;
    box-shadow:0 6px 18px rgba(0,0,0,0.5);
    text-decoration:none;
}
.btn:hover{
    filter:brightness(1.12);
}

/* Utility */
.info{
    color:#ccc;
    font-size:14px;
    margin-top:8px;
    text-align:center;
}
.small{
    font-size:13px;
    color:#999;
}

/* Thanks page */
.thanks-background{
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(6px);
    z-index: 10;
    justify-content: center;
    align-items: center;
}

.thanks-container{
    position: absolute;
    margin: 0 auto;
    text-align:center;
    max-width:500px;
    padding:40px 24px;
    background:#131314;
    border-radius:14px;
    box-shadow:0 8px 30px rgba(0,0,0,0.5);
    animation: fadeIn .4s ease;
}
.thanks-container h1{
    margin:0 0 12px;
    font-size:32px;
    font-weight:700;
}
.thanks-container p{
    margin:0 0 20px;
    font-size:17px;
    color:#ccc;
}

@keyframes fadeIn{
    from{opacity:0;transform:translateY(8px);}
    to{opacity:1;transform:translateY(0);}
}

/* Progress bar */
.progressWrap{
  display:flex;
  align-items:center;
  gap:16px;
  margin:8px 0 6px;
  justify-content:space-between;
}
.progressInner{
  flex:1;
  height:12px;
  background:rgba(255,255,255,0.06);
  border-radius:999px;
  overflow:hidden;
  box-shadow:inset 0 1px 0 rgba(255,255,255,0.02);
}
.progressFill{
  height:100%;
  width:0%;
  background: linear-gradient(90deg,var(--accent), #2bdc9a);
  transition:width .28s ease;
}
.progressLabel{
  min-width:120px;
  text-align:right;
  font-size:13px;
  color:#cfead6;
  font-weight:600;
}
.progressBadge{
  margin-left:12px;
  background:rgba(0,0,0,0.35);
  color:#cfead6;
  padding:6px 10px;
  border-radius:999px;
  font-size:13px;
  box-shadow:0 6px 18px rgba(0,0,0,0.4);
}

/* make progress sticky on wide screens */
.progressContainer{
  position:sticky;
  top:14px;
  background:linear-gradient(180deg, rgba(15,15,16,0.0), rgba(15,15,16,0.6));
  padding:8px 0;
  z-index:20;
  margin-bottom:14px;
  backdrop-filter: blur(8px);
  border-radius: 12px;
}
@media (max-width:720px){
  .progressLabel{min-width:80px;font-size:12px}
}

/* Drag & Drop visual helpers */
.drag-placeholder {
  background: rgba(255,255,255,0.06);
  border: 2px dashed var(--accent);
  height: 48px;
}

.drag-hover {
  outline: 2px solid var(--accent);
  outline-offset: -2px;
}
.drag-hidden {
  opacity: 0 !important;
}

.upload-item img { transition: box-shadow .12s, border-color .12s; }
.upload-item img:hover { transform: translateY(-3px); box-shadow:0 8px 20px rgba(0,0,0,0.45); }

.meta {
  padding: 10px 4px 2px;
  text-align: left;
}

.meta-title {
  font-weight: 700;
  font-size: 15px;
  margin-bottom: 4px;
}

.meta-info {
  font-size: 14px;
  line-height: 1.3;
  margin-bottom: 4px;
}

.social-btn {
  background: rgba(255,255,255,0.08);
  color: #cfcfcf;
  padding: 4px 8px;
  font-size: 12px;
  border-radius: 6px;
  text-decoration: none;
}
.social-btn:hover {
  background: var(--accent);
  color: #000;
}

.trailerContainer {
  max-width: 700px;
  height: 394px;
  margin: 32px auto;
  box-shadow: 0 8px 30px rgba(0,0,0,0.5);
  border-radius: 12px;
  overflow: hidden;
}



/* ---------- Responsive adjustments ---------- */

/* Make container padding a bit smaller on phones */
@media (max-width: 720px) {
  .container { padding: 20px; margin: 18px auto; max-width: 940px; }
}

/* HERO: stack left/right vertically on small screens */
@media (max-width: 900px) {
  .hero { flex-direction: column; align-items: stretch; gap: 18px; padding: 28px 0; }
  .hero .left, .hero .right { flex: none; width: 100%; }
  .heroCard { max-width: 100%; padding: 20px; }
  .h1 { font-size: 26px; }
  .lead { font-size: 14px; }
  .kicker { font-size: 13px; }
  .actions { flex-direction: column; gap: 10px; align-items: stretch; }
}

/* Make the hero image smaller on small screens */
@media (max-width: 520px) {
  .heroCard img { width: 88px; }
  .h1 { font-size: 22px; }
  .lead { font-size: 13px; }
}

/* GRID: responsive card widths
   - >=1100px: behave like current (300px cards)
   - 720–1099px: two columns
   - <720px: single column
*/
.card { width: 100%; max-width: 100%; box-sizing: border-box; }

/* Use flexible grid columns using CSS variables */
@media (min-width: 1100px) {
  .grid { gap: 20px; }
  .card { flex: 0 0 240px; max-width: 320px; width: 320px; }
}

@media (min-width: 720px) and (max-width: 1099px) {
  .grid { gap: 16px; }
  .card { flex: 0 0 calc(67% - 8px); max-width: calc(100% - 8px); }
}

@media (max-width: 719px) {
  .grid { gap: 12px; }
  .card { flex: 0 0 67%; max-width: 100%; height: 100%; border-radius:10px; }
  .card img { height:100%; object-position:center; }
  .card .meta { font-size:14px; left:10px; right:10px; bottom:10px; }
  .overlay .voteText { padding:8px 12px; font-size:14px; }
}

/* Footer submit button: ensure it doesn't obscure content on small screens */
@media (max-width: 520px) {
  .footerBar { bottom:10px; padding:0 8px; }
  .btn { padding:12px 16px; font-size:15px; border-radius:10px; }
}

/* Progress bar: reduce height and labels on small screens */
@media (max-width: 720px) {
  .progressInner { height:10px; }
  .progressLabel { font-size:12px; min-width:60px; }
  .progressBadge { font-size:12px; padding:6px 8px; display:none; } /* optionally hide badge on very small screens */
}

/* Small visual polish */
@media (prefers-reduced-motion: reduce) {
  .card, .progressFill { transition: none !important; scroll-behavior: auto !important; }
}
