/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #aaffaa;
    --primary-bright: #00ff00;
    --text-color: #ffffff;
    --text-light: #88cc88;
    --bg-light: #0a0a0a;
    --bg-dark: #111111;
    --border-color: #aaffaa;
    --glow: 0 0 8px #aaffaa66, 0 0 16px #aaffaa33;
    --glow-text: 0 0 4px #aaffaa66;
    --glow-bright: 0 0 10px #00ff00, 0 0 20px #00ff0066;
    --glow-text-bright: 0 0 5px #00ff00, 0 0 10px #00ff0066;
    --transition: none;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'DotGothic16', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-color);
    line-height: 1.7;
    background-color: var(--bg-light);
    position: relative;
}

/* Scanline Effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 9999;
    background: repeating-linear-gradient(
        0deg,
        rgba(0, 0, 0, 0.1) 0px,
        rgba(0, 0, 0, 0.1) 1px,
        transparent 1px,
        transparent 3px
    );
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 24px;
}

/* Header */
.header {
    background-color: var(--bg-dark);
    border-bottom: 2px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: var(--glow);
}

.header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 24px;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-icon {
    width: 32px;
    height: 32px;
}

.site-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-bright);
    text-shadow: var(--glow-text-bright);
}

.nav {
    display: flex;
    gap: 24px;
}

.nav a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition);
    padding: 8px 0;
    position: relative;
}

.nav a:hover {
    color: var(--primary-color);
    text-shadow: var(--glow-text);
}

.nav a::before {
    content: '> ';
    opacity: 0;
}

.nav a:hover::before {
    opacity: 1;
}

/* Hamburger Menu */
.hamburger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 101;
}

.hamburger span {
    display: block;
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    box-shadow: var(--glow);
    transition: var(--transition);
}

.hamburger.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.hamburger.active span:nth-child(2) {
    opacity: 0;
}

.hamburger.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

/* Hero Section */
.hero {
    background-color: var(--bg-light);
    color: var(--primary-bright);
    text-align: center;
    padding: 80px 24px;
    border-bottom: 2px solid var(--border-color);
}

.hero-icon {
    width: 120px;
    height: 120px;
    margin-bottom: 24px;
    filter: drop-shadow(0 0 10px #00ff00) drop-shadow(0 0 20px #00ff0066);
    animation: flicker 0.1s infinite alternate;
}

@keyframes flicker {
    0% { opacity: 1; }
    100% { opacity: 0.95; }
}

.hero-title {
    font-size: 42px;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--primary-bright);
    text-shadow: var(--glow-text-bright);
    transform: translateZ(0);
    -webkit-font-smoothing: antialiased;
}

/* iPad Safari: text-shadow causes blurry text */
.is-ipad .hero-title {
    text-shadow: 0 0 1px #00ff00;
}

.hero-subtitle {
    font-size: 18px;
    opacity: 0.9;
    font-weight: 400;
    color: var(--text-color);
}

/* Section Styles */
.section {
    padding: 80px 0;
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.section.fade-in {
    opacity: 1;
    transform: translateY(0);
}

.section-light {
    background-color: var(--bg-light);
}

.section-dark {
    background-color: var(--bg-dark);
}

.section-header {
    text-align: center;
    margin-bottom: 48px;
}

.section-title {
    font-size: 32px;
    font-weight: 700;
    color: var(--text-color);
}

.section-title::before {
    content: '[ ';
}

.section-title::after {
    content: ' ]';
}

/* Content Box */
.content-box {
    background-color: var(--bg-dark);
    padding: 40px;
    border-radius: 0;
    border: 2px solid var(--border-color);
    box-shadow: var(--glow);
    max-width: 800px;
    margin: 0 auto;
}

.description {
    font-size: 16px;
    line-height: 1.8;
    text-align: center;
    color: var(--text-color);
}

/* Member Card */
.member-card {
    background-color: var(--bg-dark);
    padding: 40px;
    border-radius: 0;
    border: 2px solid var(--border-color);
    box-shadow: var(--glow);
    max-width: 700px;
    margin: 0 auto;
    transition: var(--transition);
}

.member-card:hover {
    box-shadow: 0 0 12px #aaffaa88, 0 0 24px #aaffaa44;
}

.member-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 16px;
}

.member-name::before {
    content: '> ';
    color: var(--primary-color);
}

.member-description {
    font-size: 16px;
    line-height: 1.8;
    margin-bottom: 12px;
    color: var(--text-color);
}

.member-profile {
    font-size: 14px;
    color: var(--text-color);
}

/* Projects Grid */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 24px;
}

.project-card {
    background-color: var(--bg-dark);
    padding: 28px;
    border-radius: 0;
    border: 2px solid var(--border-color);
    box-shadow: var(--glow);
    transition: var(--transition);
}

.project-card:hover {
    box-shadow: 0 0 12px #aaffaa88, 0 0 24px #aaffaa44;
}

.project-tag {
    display: inline-block;
    background-color: transparent;
    color: var(--primary-color);
    padding: 4px 12px;
    border-radius: 0;
    border: 1px solid var(--primary-color);
    font-size: 12px;
    font-weight: 500;
    margin-bottom: 16px;
}

.project-tag.award {
    background-color: var(--primary-color);
    color: var(--bg-dark);
    font-weight: 600;
    border: none;
}

.project-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 8px;
    line-height: 1.5;
}

.project-link {
    color: var(--text-color);
    text-decoration: none;
    transition: var(--transition);
}

.project-link:hover {
    color: var(--primary-color);
    text-shadow: var(--glow-text);
}

.project-description {
    font-size: 14px;
    color: var(--text-color);
    margin-bottom: 8px;
}

.project-award {
    font-size: 13px;
    color: var(--text-color);
    font-weight: 500;
    margin-top: 8px;
}

/* Overview Table */
.overview-table {
    background-color: var(--bg-dark);
    border-radius: 0;
    border: 2px solid var(--border-color);
    box-shadow: var(--glow);
    overflow: hidden;
    max-width: 800px;
    margin: 0 auto;
}

.table-row {
    display: grid;
    grid-template-columns: 200px 1fr;
    border-bottom: 1px solid var(--border-color);
}

.table-row:last-child {
    border-bottom: none;
}

.table-label {
    background-color: var(--bg-light);
    padding: 20px 24px;
    font-weight: 600;
    color: var(--text-color);
    border-right: 1px solid var(--border-color);
}

.table-value {
    padding: 20px 24px;
    color: var(--text-color);
}

/* Links */
.link {
    color: var(--text-color);
    text-decoration: underline;
    transition: var(--transition);
}

.link:hover {
    color: var(--primary-color);
    text-shadow: var(--glow-text);
}

/* Form Container */
.form-container {
    max-width: 800px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
}

.form-container iframe {
    width: 100%;
    max-width: 640px;
    height: 1058px;
    border: 2px solid var(--border-color);
    border-radius: 0;
    box-shadow: var(--glow);
}

/* Footer */
.footer {
    background-color: var(--bg-dark);
    color: var(--primary-color);
    text-align: center;
    padding: 32px 24px;
    border-top: 2px solid var(--border-color);
    box-shadow: var(--glow);
}

.footer p {
    font-size: 14px;
    text-shadow: var(--glow-text);
}

/* Responsive Design */
@media (max-width: 768px) {
    .header .container {
        flex-direction: row;
        justify-content: space-between;
        padding: 12px 24px;
    }

    .hamburger {
        display: flex;
    }

    .nav {
        position: fixed;
        top: 0;
        right: -100%;
        width: 70%;
        max-width: 300px;
        height: 100vh;
        background-color: var(--bg-dark);
        flex-direction: column;
        gap: 0;
        padding: 80px 0 40px;
        border-left: 2px solid var(--border-color);
        box-shadow: var(--glow);
        transition: right 0.3s ease;
        z-index: 100;
    }

    .nav.active {
        right: 0;
    }

    .nav a {
        padding: 16px 32px;
        font-size: 16px;
        border-bottom: 1px solid var(--border-color);
    }

    .nav a::before {
        display: none;
    }

    .logo-icon {
        width: 28px;
        height: 28px;
    }

    .site-title {
        font-size: 18px;
    }

    .hero {
        padding: 60px 24px;
    }

    .hero-icon {
        width: 60px;
        height: 60px;
    }

    .hero-title {
        font-size: 32px;
    }

    .hero-subtitle {
        font-size: 16px;
    }

    .section {
        padding: 60px 0;
    }

    .section-title {
        font-size: 26px;
    }

    .content-box,
    .member-card {
        padding: 28px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .table-row {
        grid-template-columns: 1fr;
    }

    .table-label {
        border-right: none;
        border-bottom: 1px solid var(--border-color);
    }

    .form-container iframe {
        max-width: 100%;
        height: 900px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 16px;
    }

    .header .container {
        padding: 12px 16px;
    }

    .site-title {
        font-size: 16px;
    }

    .logo-icon {
        width: 24px;
        height: 24px;
    }

    .nav {
        width: 80%;
    }

    .hero-title {
        font-size: 28px;
    }

    .section-title {
        font-size: 24px;
    }

    .content-box,
    .member-card,
    .project-card {
        padding: 20px;
    }

    .table-label,
    .table-value {
        padding: 16px;
    }

    .form-container iframe {
        height: 800px;
    }
}
