/* ===== ROOT VARS ===== */
:root{
  --header-h: 48px; /* JS can overwrite */
  --accent: #d3709a; /* default accent (matches header pink) */
  --accent-hover: #b85c87;
}

/* ===== PAGE BASE ===== */
body.submissions-page{
  background:#fff;
  font-family:'Lexend', sans-serif;
}

/* ===== PINK BLUR TOP RIGHT ===== */
.blur-background{
  position:fixed;
  top:-120px;
  right:-120px;
  width:500px;
  height:500px;
  background:#d77c82; /* match header */
  filter:blur(120px);
  opacity:0.35;       /* lower because this pink is darker */
  border-radius:50%;
  z-index:-1;
  animation:pulseBlur 10s ease-in-out infinite;
}

@keyframes pulseBlur{
  0%,100%{ transform:scale(1); }
  50%{ transform:scale(2.2); }
}
@media (prefers-reduced-motion: reduce){
  .blur-background{ animation:none; }
}

/* ===== WRAPPER AND LAYOUT ===== */
.submission-wrapper{
  display:flex;
  justify-content:space-between;
  max-width:1400px;
  margin:0 auto;
  padding:4rem 5%;
}

/* LEFT COLUMN (fixed on desktop) */
.left-col{
  position:fixed;
  top:var(--header-h);
  left:0;
  width:600px; /* keep in sync with .right-col margin-left */
  height:calc(100vh - var(--header-h));
  z-index:1;
}
@supports (height: 100dvh){
  .left-col{ height:calc(100dvh - var(--header-h)); }
}

/* Container for frame + content */
.svg-box{
  position:relative;
  width:100%;
  height:100%;
  overflow:hidden;
  min-width:560px; /* prevents collapse on desktop */
}

/* Optional border image (if enabled) */
.rotating-svg{
  position:absolute;
  top:0;
  left:0;
  height:100%;
  width:auto;
  display:block;
}

/* Overlay content layer */
.svg-content{
  position:absolute;
  inset:0;
  padding:3rem 2rem 3rem 3.5rem;
  display:flex;
  flex-direction:column;
  align-items:flex-start;
  justify-content:flex-start;

  /* Block clicks by default; enable on interactive children */
  pointer-events:none;
}

/* Title */
.hardanger-header{
  font-family:'Hardanger', sans-serif;
  font-size:8rem;
  line-height:8rem;
  margin:0 0 2rem;
  color:var(--accent);
  text-align:left;
  pointer-events:auto;
}

/* CTA & deadline */
.submit-button,
.deadline{
  pointer-events:auto;
}

.submit-button{
  background-color:var(--accent);
  color:#fff;
  padding:0.75rem 1.5rem;
  border-radius:8px;
  border:1px solid var(--accent);
  font-weight:600;
  margin-bottom:1rem;
  text-decoration:none;
  display:inline-block;
}
.submit-button:hover{ background-color:var(--accent-hover); border-color:var(--accent-hover); }

.deadline{
  font-weight:300;
  font-size:1rem;
  color:#000;
  margin-top:0.5rem;
}

/* Visible focus for keyboard users */
.terms-link:focus,
.submit-button:focus,
.close-btn:focus{
  outline:2px solid var(--accent);
  outline-offset:2px;
}

/* ===== RIGHT COLUMN ===== */
.right-col{
  margin-left:600px; /* keep in sync with .left-col width */
  padding:4rem 5%;
  max-width:800px;
  font-weight:300;
  font-size:1rem;
  line-height:1.6;
  position:relative;
  z-index:2;
}
.right-col ul{ padding-left:1.25rem; }
.right-col li{ margin-bottom:0.5rem; }

/* ===== MODAL (T&C) ===== */
.terms-link{ text-decoration:underline; }

.modal-overlay{
  display:none;
  position:fixed;
  inset:0;
  background:rgba(0,0,0,0.7);
  z-index:9999;
  justify-content:center;
  align-items:center;
  padding:1rem;
}

.modal-content{
  background:#fff;
  color:#000;
  width:min(680px, 92vw);
  max-height:80vh;
  border-radius:12px;
  padding:1rem 1.25rem 1.25rem;
  position:relative;
  box-shadow:0 8px 28px rgba(0,0,0,0.3);
}

.modal-scroll{
  max-height:60vh;
  overflow-y:auto;
  line-height:1.45;
  font-size:0.95rem;
}

.close-btn{
  position:absolute;
  top:0.5rem;
  right:0.7rem;
  font-size:1.6rem;
  background:transparent;
  border:none;
  cursor:pointer;
  line-height:1;
}

/* ===== MOBILE ===== */
@media (max-width: 768px){
  body{ overflow-x:hidden; }

  .submission-wrapper{
    flex-direction:column;
    padding:0;
  }

  .left-col{
    position:relative;
    top:0;
    width:100%;
    height:auto;

    /* ↓ less horizontal padding, more top breathing room */
    padding:2.75rem 0.75rem 2rem;

    display:flex;
    justify-content:flex-start;
  }

  .svg-box{
    width:100%;
    max-width:540px;   /* ↓ slightly narrower so text pulls left */
    margin:0;
    min-width:0;
    height:auto;
    min-height:340px;
    overflow:hidden;
  }

  /* If border image is enabled later */
  .rotating-svg{
    position:relative;
    width:100%;
    height:auto;
    display:block;
  }

  .svg-content{
    position:relative;
    inset:auto;

    /* ↓ tighter left edge, more air above */
    padding:1.25rem 0.75rem 1.5rem;

    pointer-events:auto;
  }

  .hardanger-header{
    font-size:5rem;
    line-height:5rem;

    /* ↓ creates visual separation from top of page */
    margin-top:0.5rem;
    margin-bottom:1rem;
  }

  .submit-button{
    font-size:0.9rem;
    padding:0.5rem 1rem;
  }

  .right-col{
    margin-left:0;
    padding:2rem 1.25rem;
    width:100%;
  }
}



/* ===== PAGE THEMES ===== */
/* Kiln page: Rosemary Black + black title, button hue matches header */
body.kiln-submissions{
  --accent:#d77c82;        /* matches site header */
  --accent-hover:#c86b71;  /* slightly darker for hover */
}

body.kiln-submissions .hardanger-header{
  font-family:'Rosemary', sans-serif; /* match homepage */
  font-weight:900;
  color:#000;
}
