/* SGC Academic Activities - public display layer.
 * The WordPress parent theme supplies the site header, menus, footer and base typography.
 * These styles are intentionally scoped to the events content so the parent theme is not altered.
 */
:root{
  --sgc-purple:#3f3b80;
  --sgc-purple-dark:#292650;
  --sgc-red:#b52b2b;
  --sgc-red-dark:#8f2023;
  --sgc-ink:#20243a;
  --sgc-muted:#6f7487;
  --sgc-paper:#fff;
  --sgc-bg:#f6f7fb;
  --sgc-line:#e6e7ef;
  --sgc-shadow:0 18px 50px rgba(31,29,67,.09);
  --sgc-radius:18px;
}
.sgc-events-page{background:var(--sgc-bg);color:var(--sgc-ink);min-height:60vh;padding:0 0 35px;font-family:inherit}
.sgc-events-page *{box-sizing:border-box}
.sgc-events-container{width:min(1320px,calc(100% - 36px));margin:0 auto}
.sgc-events-page a{color:inherit}

/* Landing hero */
.sgc-events-page .hero{position:relative;overflow:hidden;margin:28px 0 20px;padding:48px 50px;border-radius:24px;background:linear-gradient(118deg,var(--sgc-purple-dark),var(--sgc-purple));color:#fff;box-shadow:var(--sgc-shadow)}
.sgc-events-page .hero:before{content:"";position:absolute;width:390px;height:390px;border-radius:50%;right:-130px;top:-190px;background:rgba(181,43,43,.18);border:1px solid rgba(255,255,255,.08)}
.sgc-events-page .hero:after{content:"";position:absolute;width:220px;height:220px;border-radius:50%;right:100px;bottom:-160px;background:rgba(255,255,255,.05)}
.sgc-events-page .hero>div{position:relative;z-index:1;max-width:850px}
.sgc-events-page .eyebrow{display:inline-flex;padding:6px 11px;border:1px solid rgba(255,255,255,.25);border-radius:999px;font-size:10px;letter-spacing:1.8px;font-weight:800;margin-bottom:11px}
.sgc-events-page .hero h1{font-size:clamp(32px,4vw,50px);line-height:1.05;margin:0 0 12px;letter-spacing:-1.3px;color:#fff}
.sgc-events-page .hero p{max-width:740px;margin:0;color:#e9e9f4;font-size:15px}

/* Filters */
.sgc-events-page .filters{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:10px;margin:0 0 16px;padding:16px;background:var(--sgc-paper);border:1px solid var(--sgc-line);border-radius:16px;box-shadow:0 8px 28px rgba(31,29,67,.045)}
.sgc-events-page .filters input,.sgc-events-page .filters select{width:100%;height:44px;padding:0 12px;border:1px solid #d8d9e4;border-radius:10px;background:#fff;color:var(--sgc-ink);font:inherit;font-size:13px;outline:none}
.sgc-events-page .filters input:focus,.sgc-events-page .filters select:focus{border-color:var(--sgc-purple);box-shadow:0 0 0 3px rgba(63,59,128,.10)}
.sgc-events-page .button{display:inline-flex;align-items:center;justify-content:center;min-height:42px;border:0;border-radius:10px;padding:0 16px;background:var(--sgc-red);color:#fff!important;text-decoration:none;font-weight:750;font-size:13px;cursor:pointer;transition:.2s ease}
.sgc-events-page .button:hover{background:var(--sgc-red-dark);transform:translateY(-1px)}
.sgc-events-page .button.secondary{background:#fff;color:var(--sgc-purple-dark)!important;border:1px solid #d9dae4}
.sgc-events-page .button.secondary:hover{background:#f4f3fa}
.sgc-events-page .result-count{color:var(--sgc-muted);font-size:13px;margin:16px 2px}

/* Cards */
.sgc-events-page .cards{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px;padding-bottom:30px}
.sgc-events-page .card{background:var(--sgc-paper);border:1px solid var(--sgc-line);border-radius:var(--sgc-radius);overflow:hidden;box-shadow:0 7px 28px rgba(31,29,67,.055);transition:transform .2s ease,box-shadow .2s ease}
.sgc-events-page .card:hover{transform:translateY(-4px);box-shadow:var(--sgc-shadow)}
.sgc-events-page .card img,.sgc-events-page .placeholder{width:100%;height:215px;object-fit:cover;display:block}
.sgc-events-page .placeholder{display:grid;place-items:center;background:linear-gradient(135deg,#ecebf7,#f8eaea);color:var(--sgc-purple);font-size:36px;font-weight:900;letter-spacing:1px}
.sgc-events-page .card-body{padding:20px}
.sgc-events-page .meta{font-size:12px;color:var(--sgc-muted);font-weight:650}
.sgc-events-page .card h2{font-size:19px;line-height:1.25;margin:8px 0 9px;color:var(--sgc-purple-dark)}
.sgc-events-page .tags{display:flex;gap:6px;flex-wrap:wrap;margin:10px 0 13px}
.sgc-events-page .tags span{background:#f0eff9;color:var(--sgc-purple-dark);border:1px solid #e1dfef;border-radius:999px;padding:4px 8px;font-size:10px;font-weight:750}
.sgc-events-page .card-body p{font-size:13px;color:#5f6476;min-height:62px;margin:0 0 14px}
.sgc-events-page .readmore{font-size:13px;font-weight:800;color:var(--sgc-red);text-decoration:none}
.sgc-events-page .readmore:hover{text-decoration:underline}
.sgc-events-page .empty{padding:28px;border-radius:14px;margin:20px 0;background:#fff;border:1px solid var(--sgc-line);text-align:center;color:var(--sgc-muted)}

/* Detail */
.sgc-events-page .detail{background:#fff;border:1px solid var(--sgc-line);border-radius:22px;padding:28px;margin:30px 0 40px;box-shadow:var(--sgc-shadow)}
.sgc-events-page .detail-cover{width:100%;max-height:600px;object-fit:cover;border-radius:15px;display:block}
.sgc-events-page .detail-content{max-width:980px;margin:25px auto 0}
.sgc-events-page .detail-content>.meta{font-size:13px}
.sgc-events-page .detail-content>h1{font-size:clamp(30px,4vw,44px);line-height:1.1;color:var(--sgc-purple-dark);margin:8px 0 20px;letter-spacing:-.7px}
.sgc-events-page .facts{display:grid;grid-template-columns:repeat(2,1fr);gap:1px;background:var(--sgc-line);margin:25px 0;border:1px solid var(--sgc-line);border-radius:13px;overflow:hidden}
.sgc-events-page .facts div{background:#fff;padding:14px 16px}
.sgc-events-page .facts strong{display:block;font-size:10px;text-transform:uppercase;letter-spacing:.8px;color:var(--sgc-muted);margin-bottom:4px}
.sgc-events-page .facts span{font-weight:700;font-size:14px}
.sgc-events-page .detail section{margin:28px 0}
.sgc-events-page .detail section h2,.sgc-events-page .detail>h2{font-size:21px;color:var(--sgc-purple-dark);margin:0 0 12px;display:flex;align-items:center;gap:9px}
.sgc-events-page .detail section h2:before,.sgc-events-page .detail>h2:before{content:"";width:4px;height:20px;border-radius:4px;background:var(--sgc-red);flex:0 0 4px}
.sgc-events-page .prose{line-height:1.8;color:#4d5264;font-size:14px}
.sgc-events-page .prose p{margin:0 0 12px}
.sgc-events-page .prose h1,.sgc-events-page .prose h2,.sgc-events-page .prose h3{color:var(--sgc-purple-dark)}
.sgc-events-page .resources-view{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.sgc-events-page .resource-card{padding:17px;border:1px solid var(--sgc-line);border-radius:13px;background:#fafafd}
.sgc-events-page .resource-card h3{margin:0 0 5px;color:var(--sgc-purple-dark);font-size:16px}
.sgc-events-page .resource-card>div{font-size:13px;color:var(--sgc-muted)}
.sgc-events-page .gallery{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px}
.sgc-events-page .gallery a{display:block;overflow:hidden;border-radius:12px;background:#eee}
.sgc-events-page .gallery img{width:100%;height:175px;object-fit:cover;display:block;transition:transform .25s ease}
.sgc-events-page .gallery a:hover img{transform:scale(1.04)}
.sgc-events-page .doc-table{border-collapse:collapse;width:100%;margin:15px 0}
.sgc-events-page .doc-table td{border:1px solid var(--sgc-line);padding:8px}

@media(max-width:1000px){
  .sgc-events-page .cards{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sgc-events-page .filters{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sgc-events-page .gallery{grid-template-columns:repeat(3,minmax(0,1fr))}
}
@media(max-width:650px){
  .sgc-events-container{width:min(100% - 24px,1320px)}
  .sgc-events-page .hero{padding:32px 24px;border-radius:18px}
  .sgc-events-page .hero h1{font-size:31px}
  .sgc-events-page .filters{grid-template-columns:1fr;padding:12px}
  .sgc-events-page .cards,.sgc-events-page .facts,.sgc-events-page .resources-view{grid-template-columns:1fr}
  .sgc-events-page .detail{padding:18px;border-radius:17px}
  .sgc-events-page .gallery{grid-template-columns:repeat(2,minmax(0,1fr))}
  .sgc-events-page .gallery img{height:135px}
}

/* ==========================================================
   SGC ACADEMIC ACTIVITIES - SUBMISSION FORM
   Scoped to .form-card so the public display remains unchanged.
   ========================================================== */
.form-card{
  width:min(1240px,calc(100% - 36px));
  margin:34px auto 50px;
  padding:30px 34px 34px;
  background:#fff;
  border:1px solid var(--sgc-line,#e6e7ef);
  border-radius:20px;
  box-shadow:0 14px 45px rgba(31,29,67,.08);
  color:var(--sgc-ink,#20243a);
  font-family:inherit;
  box-sizing:border-box;
}
.form-card *{box-sizing:border-box}
.form-card h1{
  margin:0 0 8px;
  color:var(--sgc-purple-dark,#292650);
  font-size:clamp(28px,3vw,38px);
  line-height:1.15;
  letter-spacing:-.6px;
}
.form-card .notice{
  margin:0 0 25px;
  padding:12px 15px;
  border-left:4px solid var(--sgc-red,#b52b2b);
  border-radius:8px;
  background:#f8f7fc;
  color:#5d6172;
  font-size:13px;
  line-height:1.55;
}
.form-card .success,
.form-card .error{
  margin:0 0 20px;
  padding:12px 15px;
  border-radius:9px;
  font-size:13px;
  font-weight:600;
}
.form-card .success{background:#edf8f0;border:1px solid #bfe3c7;color:#216b32}
.form-card .error{background:#fff1f1;border:1px solid #efc3c3;color:#9a2626}
.form-card form{margin:0}
.form-card .grid{
  display:grid;
  grid-template-columns:repeat(3,minmax(0,1fr));
  gap:18px 20px;
  align-items:start;
}
.form-card .grid>label{
  display:flex;
  flex-direction:column;
  gap:7px;
  min-width:0;
  margin:0;
  color:#34384a;
  font-size:12px;
  font-weight:700;
  line-height:1.25;
}
.form-card .grid>label.full{grid-column:1/-1}
.form-card input[type="text"],
.form-card input[type="email"],
.form-card input[type="url"],
.form-card input[type="number"],
.form-card input[type="date"],
.form-card input[type="file"],
.form-card select,
.form-card textarea,
.form-card input:not([type]){
  width:100%;
  max-width:100%;
  min-width:0;
  margin:0;
  padding:11px 12px;
  border:1px solid #d6d8e2;
  border-radius:9px;
  background:#fff;
  color:#222638;
  font:inherit;
  font-size:13px;
  font-weight:400;
  line-height:1.4;
  outline:none;
  box-shadow:none;
  transition:border-color .18s ease,box-shadow .18s ease,background .18s ease;
}
.form-card input[type="date"],
.form-card select{height:43px}
.form-card input[type="file"]{
  padding:7px 9px;
  min-height:43px;
  cursor:pointer;
  background:#fafafd;
}
.form-card textarea{
  min-height:105px;
  resize:vertical;
}
.form-card input::placeholder,
.form-card textarea::placeholder{color:#969aaa;opacity:1}
.form-card input:focus,
.form-card select:focus,
.form-card textarea:focus{
  border-color:var(--sgc-purple,#3f3b80);
  box-shadow:0 0 0 3px rgba(63,59,128,.10);
  background:#fff;
}
.form-card input[type="file"]:focus{outline:2px solid rgba(63,59,128,.12);outline-offset:1px}
.form-card small{
  display:block;
  margin-top:-1px;
  color:#777c8d;
  font-size:11px;
  font-weight:500;
  line-height:1.45;
}
.form-card .resource-section{
  grid-column:1/-1;
  margin:2px 0 3px;
  padding:22px;
  border:1px solid #e1e2eb;
  border-radius:15px;
  background:linear-gradient(180deg,#fbfbfe 0%,#fff 100%);
}
.form-card .resource-section h2{
  margin:0 0 5px;
  color:var(--sgc-purple-dark,#292650);
  font-size:22px;
  line-height:1.2;
}
.form-card .resource-section h2:before{display:none}
.form-card .muted{
  margin:0 0 16px;
  color:#727789;
  font-size:12px;
  line-height:1.55;
}
.form-card #resource-list{display:flex;flex-direction:column;gap:10px}
.form-card .resource-row{
  display:grid;
  grid-template-columns:1.05fr .9fr 1.15fr 1.05fr auto;
  gap:9px;
  align-items:center;
  padding:10px;
  border:1px solid #e4e5ed;
  border-radius:11px;
  background:#fff;
}
.form-card .resource-row input{min-width:0}
.form-card .button,
.form-card button.button,
.form-card button.remove-resource{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  min-height:42px;
  padding:0 17px;
  border-radius:9px;
  border:1px solid transparent;
  font-family:inherit;
  font-size:13px;
  font-weight:750;
  line-height:1;
  text-decoration:none;
  cursor:pointer;
  transition:transform .18s ease,background .18s ease,border-color .18s ease,box-shadow .18s ease;
}
.form-card .button:not(.secondary){
  background:var(--sgc-red,#b52b2b);
  color:#fff;
  box-shadow:0 5px 15px rgba(181,43,43,.16);
}
.form-card .button:not(.secondary):hover{background:var(--sgc-red-dark,#8f2023);transform:translateY(-1px)}
.form-card .button.secondary,
.form-card button.secondary{
  background:#fff;
  color:var(--sgc-purple-dark,#292650);
  border-color:#d7d8e2;
}
.form-card .button.secondary:hover,
.form-card button.secondary:hover{background:#f5f4fa;border-color:#c9c9d8}
.form-card #add-resource{margin-top:13px}
.form-card .remove-resource{
  min-height:38px!important;
  padding:0 12px!important;
  color:#9b2d2d!important;
  border-color:#e2bcbc!important;
  background:#fff!important;
  white-space:nowrap;
}
.form-card .remove-resource:hover{background:#fff3f3!important}
.form-card form>.button[type="submit"]{
  margin-top:24px;
  min-width:190px;
  min-height:47px;
  font-size:14px;
}
.form-card .upload-note{
  display:inline-block;
  margin:0 0 0 13px;
  color:#777c8d;
  font-size:11px;
  vertical-align:middle;
}
.form-card label[for]{cursor:pointer}

@media(max-width:1050px){
  .form-card .grid{grid-template-columns:repeat(2,minmax(0,1fr))}
  .form-card .resource-section{grid-column:1/-1}
  .form-card .resource-row{grid-template-columns:1fr 1fr;}
  .form-card .resource-row input[type="file"]{grid-column:1/2}
  .form-card .resource-row .remove-resource{grid-column:2/3;justify-self:end}
}
@media(max-width:680px){
  .form-card{
    width:calc(100% - 22px);
    margin:20px auto 35px;
    padding:21px 16px 24px;
    border-radius:15px;
  }
  .form-card h1{font-size:28px}
  .form-card .grid{grid-template-columns:1fr;gap:15px}
  .form-card .grid>label.full,
  .form-card .resource-section{grid-column:1}
  .form-card .resource-section{padding:16px}
  .form-card .resource-row{grid-template-columns:1fr;gap:8px}
  .form-card .resource-row input[type="file"],
  .form-card .resource-row .remove-resource{grid-column:auto}
  .form-card .resource-row .remove-resource{justify-self:stretch}
  .form-card form>.button[type="submit"]{width:100%;margin-top:20px}
  .form-card .upload-note{display:block;margin:10px 0 0;line-height:1.5}
}
