/* ==========================================================================
   秦寿会 (SHINJUKAI) CUSTOM STYLE SHEET
   Premium Golf Club Theme - Emerald Green, Gold & Cream
   ========================================================================== */

:root {
    --primary-color: #0b3c2d;       /* Deep Forest Emerald Green */
    --primary-light: #185c46;      /* Lighter Emerald */
    --primary-dark: #06241a;       /* Dark Emerald */
    --accent-color: #c59b27;        /* Matte Gold */
    --accent-hover: #b0861b;        /* Matte Gold Hover */
    --bg-cream: #faf9f6;            /* Soft Cream Warm White */
    --bg-white: #ffffff;
    --text-dark: #22252a;           /* Soft Black */
    --text-muted: #626a75;
    --border-color: #e2e8f0;
    --header-height: 80px;
    --font-serif: \'Noto Serif JP\', serif;
    --font-sans: \'Outfit\', \'Segoe UI\', Roboto, sans-serif;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-soft: 0 4px 20px rgba(11, 60, 45, 0.05);
    --shadow-medium: 0 10px 30px rgba(11, 60, 45, 0.08);
}

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

body {
    font-family: var(--font-sans);
    background-color: var(--bg-cream);
    color: var(--text-dark);
    line-height: 1.7;
    -webkit-font-smoothing: antialiased;
}

/* Header & Navigation */
.app-header {
    background-color: rgba(11, 60, 45, 0.95);
    backdrop-filter: blur(10px);
    color: var(--bg-cream);
    position: sticky;
    top: 0;
    z-index: 1000;
    border-bottom: 2px solid var(--accent-color);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
    height: var(--header-height);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.app-logo {
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: var(--bg-cream);
    transition: var(--transition-smooth);
}

.logo-kanji {
    font-family: var(--font-serif);
    font-size: 24px;
    font-weight: 700;
    letter-spacing: 2px;
    color: var(--accent-color);
    line-height: 1.1;
}

.logo-sub {
    font-size: 10px;
    font-weight: 600;
    letter-spacing: 3px;
    opacity: 0.8;
    margin-top: 2px;
}

.app-logo:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Desktop Nav Links */
.app-nav {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    list-style: none;
    align-items: center;
    gap: 8px;
}

.nav-list a {
    text-decoration: none;
    color: var(--bg-cream);
    padding: 10px 16px;
    font-size: 14.5px;
    font-weight: 500;
    border-radius: 4px;
    transition: var(--transition-smooth);
    position: relative;
}

.nav-list a:hover {
    color: var(--accent-color);
    background-color: rgba(255, 255, 255, 0.05);
}

.nav-list a.active {
    color: var(--accent-color);
    font-weight: 600;
}

.nav-list a.active::after {
    content: \'\';
    position: absolute;
    bottom: 0;
    left: 16px;
    right: 16px;
    height: 2px;
    background-color: var(--accent-color);
    border-radius: 2px;
}

/* Button Portal */
.btn-portal {
    background-color: var(--accent-color);
    color: var(--primary-dark) !important;
    font-weight: 600 !important;
    border: 1px solid var(--accent-color);
    border-radius: 20px !important;
    padding: 8px 20px !important;
    box-shadow: 0 4px 10px rgba(197, 155, 39, 0.2);
}

.btn-portal:hover {
    background-color: transparent !important;
    color: var(--accent-color) !important;
    box-shadow: none;
}

/* Back to Members Page Button */
.back-to-members-btn {
    display: inline-block;
    background-color: var(--accent-color);
    color: var(--primary-dark) !important;
    font-weight: 600 !important;
    border: 1px solid var(--accent-color);
    border-radius: 20px !important;
    padding: 10px 24px !important;
    text-decoration: none;
    box-shadow: 0 4px 10px rgba(197, 155, 39, 0.2);
    transition: var(--transition-smooth);
}

.back-to-members-btn:hover {
    background-color: transparent !important;
    color: var(--accent-color) !important;
    box-shadow: none;
}

/* Mobile Nav Toggle */
.mobile-nav-toggle {
    display: none;
    background: none;
    border: none;
    color: var(--bg-cream);
    font-size: 24px;
    cursor: pointer;
    padding: 8px;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-light) 100%);
    color: var(--bg-cream);
    padding: 80px 24px 100px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: \'\';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: radial-gradient(circle at 50% 50%, rgba(197, 155, 39, 0.1) 0%, transparent 60%);
    pointer-events: none;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    font-family: var(--font-serif);
    font-size: 16px;
    color: var(--accent-color);
    font-weight: 600;
    letter-spacing: 4px;
    margin-bottom: 16px;
    text-transform: uppercase;
}

.hero-title {
    font-family: var(--font-serif);
    font-size: 48px;
    font-weight: 700;
    line-height: 1.3;
    margin-bottom: 24px;
    letter-spacing: 1px;
}

.hero-description {
    font-size: 18px;
    opacity: 0.9;
    max-width: 600px;
    margin: 0 auto;
    font-weight: 300;
}

/* Page Headers (Standard) */
.page-header {
    background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary-color) 100%);
    color: var(--bg-cream);
    padding: 60px 24px;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.page-header-title {
    font-family: var(--font-serif);
    font-size: 36px;
    font-weight: 700;
    color: var(--bg-white);
    margin-bottom: 8px;
}

.page-header-sub {
    font-size: 14px;
    color: var(--accent-color);
    letter-spacing: 2px;
}

/* Content Layouts */
.content-section {
    max-width: 900px;
    margin: 60px auto;
    padding: 0 24px;
}

.card {
    background-color: var(--bg-white);
    border-radius: 8px;
    padding: 40px;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    margin-bottom: 40px;
    transition: var(--transition-smooth);
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-color);
}

.section-title {
    font-family: var(--font-serif);
    font-size: 26px;
    color: var(--primary-color);
    margin-bottom: 24px;
    padding-bottom: 12px;
    border-bottom: 2px solid var(--accent-color);
    display: inline-block;
}

.paragraph {
    margin-bottom: 20px;
    font-size: 16px;
    color: var(--text-dark);
}

/* Registration Button */
.registration-btn-wrapper {
    text-align: center;
    margin-top: 30px;
}

.registration-btn-img {
    width: 400px;
    height: 180px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.registration-btn-img:hover {
    opacity: 0.85;
    transform: translateY(-2px);
}

/* Back to Members Page Image Button */
.back-to-members-img {
    width: 140px;
    height: auto;
    border-radius: 8px;
    cursor: pointer;
    transition: var(--transition-smooth);
}

.back-to-members-img:hover {
    opacity: 0.85;
    transform: translateY(-2px);
}

/* Gallery Grid */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-top: 24px;
}

@media (max-width: 992px) {
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
        gap: 16px;
    }
}

.gallery-item {
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    background-color: var(--bg-white);
    transition: var(--transition-smooth);
    cursor: pointer;
}

.gallery-item:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-color);
}

.gallery-item img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    display: block;
    transition: var(--transition-smooth);
}

.gallery-item:hover img {
    transform: scale(1.03);
}

/* Schedule Table styling */
.schedule-table-wrapper {
    overflow-x: auto;
    margin-top: 24px;
}

.schedule-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 16px;
    background-color: var(--bg-white);
}

.schedule-table th,
.schedule-table td {
    padding: 16px 20px;
    text-align: left;
    border-bottom: 1px solid var(--border-color);
}

.schedule-table th {
    background-color: var(--primary-color);
    color: var(--bg-cream);
    font-weight: 600;
}

.schedule-table tr:hover {
    background-color: rgba(11, 60, 45, 0.02);
}

.badge {
    display: inline-block;
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 600;
    border-radius: 4px;
    background-color: var(--accent-color);
    color: var(--primary-dark);
}

/* Document List (Rules, Bylaws) */
.doc-list {
    list-style: none;
    counter-reset: doc-counter;
}

.doc-item {
    position: relative;
    padding-left: 50px;
    margin-bottom: 24px;
}

.doc-item::before {
    counter-increment: doc-counter;
    content: counter(doc-counter);
    position: absolute;
    left: 0;
    top: 2px;
    width: 32px;
    height: 32px;
    background-color: var(--primary-color);
    color: var(--accent-color);
    font-family: var(--font-sans);
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    font-size: 14px;
}

.doc-item h4 {
    font-family: var(--font-serif);
    font-size: 18px;
    color: var(--primary-color);
    margin-bottom: 6px;
}

/* Form Iframe Container */
.form-container {
    background-color: var(--bg-white);
    border-radius: 8px;
    box-shadow: var(--shadow-soft);
    border: 1px solid var(--border-color);
    padding: 16px;
    margin-bottom: 40px;
    position: relative;
    height: 850px;
    overflow: hidden;
}

.form-iframe {
    width: 100%;
    height: 100%;
    border: none;
}

.loading-spinner {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: var(--primary-color);
    font-size: 24px;
    z-index: 0;
}

/* Form fallback (when iframe fails to load) */
.form-fallback {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
    z-index: 1;
    padding: 30px;
}

.form-fallback p {
    font-size: 16px;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.form-fallback-link {
    display: inline-block;
    margin-top: 8px;
    padding: 12px 24px;
    background-color: var(--primary-color);
    color: var(--bg-cream);
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: var(--transition-smooth);
}

.form-fallback-link:hover {
    background-color: var(--accent-color);
    color: var(--primary-dark);
}

/* Officers Grid */
.officers-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
    margin-top: 30px;
}

.officer-card {
    background-color: var(--bg-white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 24px;
    text-align: center;
    box-shadow: var(--shadow-soft);
    transition: var(--transition-smooth);
}

.officer-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-medium);
    border-color: var(--accent-color);
}

.officer-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    background-color: rgba(11, 60, 45, 0.05);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    margin: 0 auto 16px;
    border: 2px solid var(--accent-color);
}

.officer-role {
    font-size: 12px;
    font-weight: 700;
    color: var(--accent-color);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-bottom: 4px;
}

.officer-name {
    font-family: var(--font-serif);
    font-size: 18px;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 8px;
}

.officer-desc {
    font-size: 14px;
    color: var(--text-muted);
}

/* Footer styling */
.app-footer {
    background-color: var(--primary-dark);
    color: rgba(250, 249, 246, 0.7);
    padding: 60px 24px 20px;
    border-top: 4px solid var(--accent-color);
}

.footer-icon-link {
    flex-shrink: 0;
    text-decoration: none;
    display: flex;
    align-items: center;
    transition: var(--transition-smooth);
}

.footer-icon-link:hover {
    opacity: 0.85;
    transform: translateY(-2px);
}

.footer-icon {
    width: 60px;
    height: 60px;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--accent-color);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
    background-color: var(--bg-white);
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-wrap: wrap;
    gap: 40px;
}

.footer-info {
    flex: 1 1 400px;
}

.footer-info h3 {
    font-family: var(--font-serif);
    color: var(--bg-white);
    font-size: 22px;
    margin-bottom: 12px;
}

.footer-sub {
    font-size: 10px;
    letter-spacing: 2px;
    color: var(--accent-color);
    margin-left: 8px;
}

.footer-info p {
    font-size: 14px;
    max-width: 450px;
}

.footer-links {
    list-style: none;
}

.footer-links a {
    color: var(--accent-color);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: var(--transition-smooth);
}

.footer-links a:hover {
    color: var(--bg-white);
}

.footer-bottom {
    max-width: 1200px;
    margin: 40px auto 0;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    text-align: center;
    font-size: 12px;
}

/* Responsive adjustments */
@media (max-width: 992px) {
    .nav-list {
        display: none; /* Mobile layout toggle handles it */
    }
    
    .mobile-nav-toggle {
        display: block;
    }
    
    .app-nav.nav-open .nav-list {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: var(--header-height);
        left: 0;
        right: 0;
        background-color: var(--primary-dark);
        padding: 24px;
        gap: 16px;
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
        border-bottom: 2px solid var(--accent-color);
        max-height: calc(100vh - var(--header-height));
        overflow-y: auto;
    }
    
    .app-nav.nav-open .nav-list a {
        display: block;
        width: 100%;
        font-size: 16px;
    }

    .nav-portal-item {
        margin-top: 10px;
        width: 100%;
        text-align: center;
    }
    
    .btn-portal {
        display: inline-block;
        width: 100%;
    }

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

/* ==========================================================================
   Login Page Styles (Redesigned)
   ========================================================================== */
.login-card {
    background-color: var(--bg-white);
    border-radius: 16px;
    padding: 48px 40px;
    box-shadow: 0 8px 40px rgba(11, 60, 45, 0.12);
    border: 1px solid var(--border-color);
    max-width: 500px;
    margin: 0 auto;
}

.login-header {
    text-align: center;
    margin-bottom: 40px;
}

.login-title {
    font-family: var(--font-serif);
    font-size: 28px;
    color: var(--primary-color);
    margin-bottom: 12px;
    letter-spacing: 1px;
}

.login-description {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.7;
}

.login-body {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* Login Sections (Bordered Boxes) */
.login-section {
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 28px 24px 24px;
    position: relative;
    background-color: var(--bg-cream);
    transition: var(--transition-smooth);
}

.login-section:hover {
    border-color: #d0d7de;
}

.login-section-standard {
    border-color: rgba(11, 60, 45, 0.2);
    background: linear-gradient(135deg, #f5f7f6 0%, var(--bg-cream) 100%);
}

.login-section-standard:hover {
    border-color: rgba(11, 60, 45, 0.35);
}

.login-section-label {
    position: absolute;
    top: -12px;
    left: 20px;
    background-color: var(--bg-white);
    padding: 0 12px;
    font-size: 13px;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: 0.5px;
    border-radius: 4px;
    line-height: 24px;
}

.login-section-standard .login-section-label {
    color: var(--primary-color);
}

.login-section-note {
    text-align: center;
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 16px;
    line-height: 1.5;
}

/* Login Form */
.login-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
}

.form-input {
    width: 100%;
    padding: 14px 16px;
    font-size: 16px;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    background-color: var(--bg-white);
    color: var(--text-dark);
    transition: var(--transition-smooth);
    font-family: var(--font-sans);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.04);
}

.form-input:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.04), 0 0 0 3px rgba(197, 155, 39, 0.12);
    background-color: var(--bg-white);
}

.form-input::placeholder {
    color: #b0b8c4;
}

/* Login Submit Button - 3D Style */
.btn-login-submit {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(180deg, #0e4d3a 0%, #0a3f2f 100%);
    color: var(--bg-cream);
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    letter-spacing: 1px;
    box-shadow:
        0 5px 0 #06241a,
        0 6px 16px rgba(11, 60, 45, 0.25);
    position: relative;
    top: 0;
}

.btn-login-submit:hover {
    background: linear-gradient(180deg, #125f47 0%, #0d4c38 100%);
    transform: translateY(-1px);
    box-shadow:
        0 6px 0 #06241a,
        0 8px 20px rgba(11, 60, 45, 0.3);
}

.btn-login-submit:active {
    top: 3px;
    box-shadow:
        0 2px 0 #06241a,
        0 3px 8px rgba(11, 60, 45, 0.2);
    transform: translateY(0);
}

@media (max-width: 768px) {
    .content-section {
        margin: 30px auto;
        padding: 0 16px;
    }
    
    .card {
        padding: 20px;
    }

    .header-container {
        padding: 0 16px;
    }

    .logo-kanji {
        font-size: 20px;
    }

    .logo-sub {
        font-size: 9px;
        letter-spacing: 2px;
    }

    /* Hero section adjustments */
    .hero {
        padding: 60px 16px 80px;
    }

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

    .hero-subtitle {
        font-size: 13px;
        letter-spacing: 3px;
    }

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

    /* Page headers */
    .page-header {
        padding: 40px 16px;
    }

    .page-header-title {
        font-size: 26px;
    }

    .page-header-sub {
        font-size: 12px;
    }

    /* Section titles */
    .section-title {
        font-size: 20px;
    }

    /* Registration button image - make it fluid */
    .registration-btn-img {
        width: 100%;
        max-width: 400px;
        height: auto;
    }

    /* Officers grid - single column */
    .officers-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }

    /* Form containers - reduce fixed height */
    .form-container {
        height: 650px;
        padding: 12px;
    }

    /* Schedule table - compact cells */
    .schedule-table th,
    .schedule-table td {
        padding: 12px 10px;
        font-size: 14px;
    }

    /* Document list - compact */
    .doc-item {
        padding-left: 42px;
    }

    .doc-item::before {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }

    .doc-item h4 {
        font-size: 16px;
    }

    .paragraph {
        font-size: 15px;
    }

    /* Footer - stack vertically */
    .app-footer {
        padding: 40px 16px 20px;
    }

    .footer-container {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 24px;
    }

    .footer-info {
        flex: 1 1 auto;
    }

    .footer-info p {
        max-width: 100%;
        margin: 0 auto;
    }

    .footer-bottom {
        margin: 24px auto 0;
    }

    /* Login */
    .login-card {
        padding: 32px 20px;
    }

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

    .login-section {
        padding: 24px 16px 20px;
    }

    .login-description {
        font-size: 13px;
    }
}

/* Small mobile devices */
@media (max-width: 480px) {
    .hero-title {
        font-size: 24px;
    }

    .hero {
        padding: 48px 16px 64px;
    }

    .page-header-title {
        font-size: 22px;
    }

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

    .login-card {
        padding: 24px 16px;
    }

    .login-body {
        gap: 20px;
    }

    .login-section-label {
        left: 12px;
        font-size: 12px;
    }

    .form-container {
        height: 550px;
        padding: 8px;
    }

    .doc-item {
        padding-left: 36px;
    }

    .doc-item::before {
        width: 24px;
        height: 24px;
        font-size: 11px;
    }

    .schedule-table th,
    .schedule-table td {
        padding: 10px 8px;
        font-size: 13px;
    }

    /* Gallery grid - adjust min column width for narrow screens */
    .gallery-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 12px;
    }

    .gallery-item img {
        height: 160px;
    }
}
