/* ==========================================================================
   KOJOBS UW — global styles (loaded on every page)
   Palette and structure preserved from the original; refined for spacing,
   typography, responsive images and subtle motion.
   ========================================================================== */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@500;600;700&display=swap');

:root {
    --purple-deep: #38265a;
    --purple: #6A0DAD;
    --purple-bright: #B069DB;
    --purple-hover: #8A2BE2;
    --lilac: #E5D9F2;
    --lilac-2: #CDC1FF;
    --cream: #F9F6EE;
    --sand: #E2DFD2;
    --tan: #C19A6B;
    --ink: #333;
    --shadow-sm: 0 2px 8px rgba(56, 38, 90, 0.08);
    --shadow-md: 0 8px 24px rgba(56, 38, 90, 0.12);
    --radius: 12px;
    --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

*, *::before, *::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

html, body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

body {
    font-family: Arial, "Helvetica Neue", Helvetica, sans-serif;
    line-height: 1.6;
    color: var(--ink);
    background-color: white;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, .logo {
    font-family: 'Poppins', 'Segoe UI', Arial, sans-serif;
    letter-spacing: 0.2px;
}

a {
    text-decoration: none;
    color: inherit;
}

h1 {
    margin: 0;
    font-size: clamp(2rem, 5vw, 2.5rem);
    text-align: center;
    line-height: 1.2;
}

p {
    margin: 0;
    text-align: left;
}

/* Responsive images everywhere — never let intrinsic width/height attrs
   squash a photo into the wrong aspect ratio. */
img {
    max-width: 100%;
    height: auto;
}

/* ---- Accessibility: visible keyboard focus ---- */
a:focus-visible,
button:focus-visible {
    outline: 3px solid var(--purple-bright);
    outline-offset: 3px;
    border-radius: 4px;
}

/* ==========================================================================
   Scroll reveal (paired with reveal.js)
   ========================================================================== */
.reveal {
    opacity: 0;
    transform: translateY(24px);
    transition: opacity 0.7s var(--ease), transform 0.7s var(--ease);
    will-change: opacity, transform;
}

.reveal-visible {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    .reveal { opacity: 1; transform: none; transition: none; }
    * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; }
}

/* ==========================================================================
   Main banner (home)
   ========================================================================== */
.main_banner {
    position: relative;
    background: linear-gradient(rgba(28, 18, 48, 0.45), rgba(28, 18, 48, 0.55)),
                url('images/homepage_main.jpg') no-repeat center center / cover;
    color: white;
    text-align: center;
    padding: clamp(6rem, 16vw, 11rem) 1rem;
}

.main_banner > div {
    animation: fadeUp 1.1s var(--ease) both;
}

.main_banner h1 {
    font-size: clamp(2.8rem, 9vw, 5rem);
    margin-bottom: 0.4rem;
    text-shadow: 0 2px 18px rgba(0, 0, 0, 0.35);
}

.main_banner p {
    font-size: clamp(1.05rem, 3vw, 1.5rem);
    margin-bottom: 0;
    text-shadow: 0 1px 10px rgba(0, 0, 0, 0.35);
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: none; }
}

/* Legacy keyframe kept for any page still referencing it */
@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ==========================================================================
   Section layout
   ========================================================================== */
section {
    padding: clamp(2.5rem, 6vw, 4rem) 1rem;
    text-align: center;
}

.about_us, .events, .officers, .join, .sponsors {
    margin: 1.25rem;
    border-radius: var(--radius);
    padding: clamp(1.75rem, 4vw, 3rem);
    text-align: center;
}

.explanation {
    max-width: 760px;
    margin: 0 auto;
    font-size: 1.05rem;
    line-height: 1.7;
}

.about_us { background-color: var(--purple-deep); color: white; }
.events   { background-color: var(--cream);       color: black; }
.officers { background-color: var(--lilac);        color: black; }
.sponsors { background-color: var(--lilac-2);      color: black; }
.join     { background-color: var(--sand);         color: black; }

.sponsors .explanation, .events .explanation { margin-bottom: 0; }
.sponsors .btn { margin-top: 1.25rem; }

/* Two-column rows (text + image) */
.about_us > div, .events > div, .officers > div, .join > div, .sponsors > div {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: clamp(1.5rem, 4vw, 3rem);
    flex-wrap: wrap;
    text-align: left;
}

.about_us img, .events img, .officers img, .join img, .sponsors img {
    width: min(460px, 100%);
    height: auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow-md);
    object-fit: cover;
}

/* Alternating image placement */
.events img, .join img { order: -1; }
.sponsors img { order: 1; }

@media (max-width: 768px) {
    .events img, .join img { order: 2; }
}

.about_us .text-container,
.events .text-container,
.officers .text-container,
.join .text-container,
.sponsors .text-container {
    max-width: 560px;
    text-align: center;
}

.about_us h1, .events h1, .officers h1, .join h1, .sponsors h1 {
    font-size: clamp(1.8rem, 4.5vw, 2.6rem);
    margin-bottom: 1rem;
}

.join .btn { margin-top: 1.25rem; }

/* ==========================================================================
   Buttons
   ========================================================================== */
.btn {
    display: inline-block;
    margin-top: 1.25rem;
    padding: 0.7rem 1.9rem;
    background-color: var(--purple-bright);
    color: white;
    border-radius: 999px;
    font-weight: bold;
    transition: background-color 0.3s var(--ease),
                transform 0.2s var(--ease),
                box-shadow 0.3s var(--ease);
}

.btn:hover {
    background-color: var(--purple-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 18px rgba(138, 43, 226, 0.28);
}

.btn:active {
    transform: translateY(0);
}

/* Membership nav link accent */
.navbar ul li a[href="membership.html"] {
    font-weight: bold;
    color: #FFD700;
    text-shadow: 1px 1px 2px #000;
    transition: transform 0.3s var(--ease), color 0.3s var(--ease);
}

.navbar ul li a[href="membership.html"]:hover {
    transform: scale(1.08);
    color: #FFA500;
}
