
/* =================================
   JICA ALUMNI ASSOCIATION WEBSITE
   Shared design for all six pages
   ================================= */

/* 1. Basic settings */
* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 16px;
    line-height: 1.7;
    color: #263445;
    background-color: #f4f7fb;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

h1, h2, h3 {
    color: #12345a;
    line-height: 1.3;
}

h1 {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
}

h2 {
    font-size: clamp(1.4rem, 3vw, 2rem);
}

p {
    margin-top: 0;
}

/* 2. Header */
header {
    background-color: #ffffff;
    color: #12345a;
    padding: 20px;
}

header h1,
header h2,
header p {
    color: #12345a;
}

/* 3. Navigation menu */
nav {
    background-color: #1c4d7a;
    padding: 10px 16px;
}

nav a {
    display: inline-block;
    color: white;
    text-decoration: none;
    padding: 10px 14px;
    margin: 2px;
    border-radius: 5px;
    font-weight: bold;
}

nav a:hover,
nav a:focus {
    background-color: #ffffff;
    color: #12345a;
}

/* 4. Main page content */
main {
    width: 100%;
    max-width: 1150px;
    margin: 0 auto;
    padding: 28px 20px;
}

section {
    margin-bottom: 35px;
}

section h2 {
    border-bottom: 3px solid #c83c45;
    padding-bottom: 8px;
}

/* 5. Links and buttons */
a {
    color: #165d99;
}

button,
input[type="submit"] {
    background-color: #12345a;
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 6px;
    font-size: 1rem;
    cursor: pointer;
}

button:hover,
input[type="submit"]:hover {
    background-color: #1c4d7a;
}

/* 6. Reusable cards */
.card,
.member-card,
.event-card,
.gallery-item {
    background-color: white;
    border-radius: 10px;
    padding: 18px;
    margin-bottom: 20px;
    box-shadow: 0 3px 12px rgba(20, 45, 70, 0.08);
}

.member-card img,
.event-card img,
.gallery-item img {
    width: 100%;
    border-radius: 7px;
    object-fit: cover;
}

/* 7. Responsive grids */
.member-grid,
.events-grid,
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 10px;
}

/* 8. Contact form */
form {
    max-width: 700px;
    width: 100%;
}

input,
textarea,
select {
    max-width: 100%;
    font: inherit;
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="subject"],
textarea,
select {
    width: 100%;
    padding: 12px;
    margin: 6px 0 18px;
    border: 1px solid #b8c4d1;
    border-radius: 6px;
    background-color: white;
}

textarea {
    min-height: 140px;
    resize: vertical;
}

input:focus,
textarea:focus,
select:focus {
    outline: 2px solid #3979b8;
    outline-offset: 1px;
}

/* 9. Footer */
footer {
    background-color: #12345a;
    color: white;
    text-align: center;
    padding: 22px 16px;
    margin-top: 30px;
}

footer a {
    color: white;
}

/* 10. Tablet screens */
@media (max-width: 900px) {
    .member-grid,
    .events-grid,
    .gallery-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* 11. Mobile phones */
@media (max-width: 600px) {
    body {
        font-size: 15px;
    }

    header {
        padding: 14px 12px;
    }

    nav {
        padding: 8px;
    }

    nav a {
        display: block;
        text-align: center;
        margin: 4px 0;
        padding: 10px;
    }

    main {
        padding: 20px 14px;
    }

    .member-grid,
    .events-grid,
    .gallery-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .card,
    .member-card,
    .event-card,
    .gallery-item {
        padding: 14px;
    }

    input[type="text"],
    input[type="email"],
    input[type="tel"],
    input[type="subject"],
    textarea,
    select,
    input[type="submit"],
    button {
        width: 100%;
    }
}


/* =================================
   HOMEPAGE DESIGN
   ================================= */

.hero {
    background: linear-gradient(
        120deg,
        #12345a,
        #1c4d7a
    );
    color: white;
    padding: 65px 35px;
    border-radius: 14px;
    margin-bottom: 35px;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
}

.hero h1 {
    color: white;
    margin: 12px 0 20px;
}

.hero p {
    font-size: 1.1rem;
}

.hero-label {
    text-transform: uppercase;
    letter-spacing: 2px;
    font-weight: bold;
    font-size: 0.85rem !important;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 25px;
}

.button-link {
    display: inline-block;
    background-color: #ffffff;
    color: #12345a;
    text-decoration: none;
    font-weight: bold;
    padding: 12px 20px;
    border-radius: 6px;
    border: 2px solid white;
}

.button-link:hover,
.button-link:focus {
    background-color: #e9f1fa;
}

.button-outline {
    background-color: transparent;
    color: white;
}

.button-outline:hover,
.button-outline:focus {
    background-color: white;
    color: #12345a;
}

.home-about,
.home-features,
.home-cooperation {
    margin-bottom: 38px;
}

.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 22px;
}

.feature-card {
    background-color: white;
    padding: 24px;
    border-radius: 10px;
    border-top: 4px solid #c83c45;
    box-shadow: 0 3px 12px rgba(20, 45, 70, 0.08);
}

.feature-card h3 {
    margin-top: 0;
}

.feature-card a {
    font-weight: bold;
    text-decoration: none;
}

.home-cooperation {
    background-color: #e7eef6;
    padding: 30px;
    border-radius: 10px;
}

.home-cooperation .button-link {
    background-color: #12345a;
    color: white;
    border-color: #12345a;
}

@media (max-width: 900px) {
    .feature-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 600px) {
    .hero {
        padding: 35px 18px;
    }

    .hero-buttons {
        flex-direction: column;
    }

    .hero-buttons a {
        width: 100%;
        text-align: center;
    }

    .feature-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .home-cooperation {
        padding: 22px 16px;
    }
}

/* Header: logo left, title centre, flags right */

header {
    padding: 15px 25px;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    max-width: 1200px;
    width: 100%;
    margin: 0 auto;
}

.header-logo {
    flex: 0 0 100px;
}

.header-logo img {
    display: block;
    width: 90px;
    height: auto;
}

.header-title {
    flex: 1;
    text-align: center;
}

.header-title h1 {
    margin: 0;
    font-size: 26px;
}

.header-title p {
    margin: 4px 0 0;
}

.header-flags {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 10px;
    flex: 0 0 110px;
}

.header-flags img {
    display: block;
    width: 60px;
    height: auto;
}

/* Mobile phone layout */
@media (max-width: 600px) {
    header {
        padding: 12px;
    }

    .header-inner {
        gap: 10px;
    }

    .header-logo {
        flex-basis: 55px;
    }

    .header-logo img {
        width: 55px;
    }

    .header-title {
        min-width: 0;
    }

    .header-title h1 {
        font-size: 16px;
    }

    .header-title p {
        font-size: 13px;
    }

    .header-flags {
        flex-basis: 65px;
        gap: 5px;
    }

    .header-flags img {
        width: 28px;
    }
}

/* FORCE HEADER ELEMENTS INTO LEFT, CENTRE, RIGHT */

header .header-inner {
    display: grid !important;
    grid-template-columns: 100px minmax(0, 1fr) 110px !important;
    align-items: center !important;
    width: 100% !important;
    max-width: 1200px !important;
    margin-left: auto !important;
    margin-right: auto !important;
    gap: 15px !important;
}

header .header-logo {
    grid-column: 1 !important;
    justify-self: start !important;
}

header .header-title {
    grid-column: 2 !important;
    text-align: center !important;
    min-width: 0 !important;
}

header .header-flags {
    grid-column: 3 !important;
    justify-self: end !important;
    display: flex !important;
    justify-content: flex-end !important;
    align-items: center !important;
    gap: 8px !important;
}

header .header-logo img {
    width: 85px !important;
    height: auto !important;
}

header .header-flags img {
    width: 42px !important;
    height: auto !important;
}

/* MOBILE */
@media (max-width: 600px) {
    header .header-inner {
        grid-template-columns: 55px minmax(0, 1fr) 65px !important;
        gap: 8px !important;
    }

    header .header-logo img {
        width: 52px !important;
    }

    header .header-title h1 {
        font-size: 15px !important;
    }

    header .header-flags img {
        width: 27px !important;
    }
}

/* Association header layout */

header .header-inner {
    display: grid;
    grid-template-columns: 100px minmax(0, 1fr) 110px;
    align-items: center;
    gap: 15px;
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
}

header .header-logo {
    grid-column: 1;
    justify-self: start;
}

header .header-logo .logo {
    display: block;
    width: 85px;
    height: auto;
}

header .header-title {
    grid-column: 2;
    text-align: center;
    min-width: 0;
}

header .header-title h1 {
    margin: 0;
    font-size: 24px;
}

header .header-title p {
    margin: 5px 0 0;
}

header .flags {
    grid-column: 3;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: 8px;
}

header .flags img {
    display: block;
    width: 100px;
    height: auto;
}

/* Mobile layout */
@media (max-width: 600px) {
    header .header-inner {
        grid-template-columns: 55px minmax(0, 1fr) 62px;
        gap: 6px;
    }

    header .header-logo .logo {
        width: 50px;
    }

    header .header-title h1 {
        font-size: 15px;
    }

    header .header-title p {
        font-size: 12px;
    }

    header .flags {
        gap: 4px;
    }

    header .flags img {
        width: 27px;
    }
}

.form-buttons {
    display: flex;
    gap: 5px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.form-buttons button {
    padding: 12px 22px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
}

.form-buttons button[type="submit"] {
    background-color: #003366;
    color: white;
}

.form-buttons button[type="reset"] {
    background-color: #e0e0e0;
    color: #222222;
}

.form-buttons button:hover {
    opacity: 0.85;
}

/* Useful Links Section */
.useful-links {
    background-color: #173d61;
    color: white;
    text-align: center;
    padding: 8px 10px;
    margin: 10px auto;
    max-width: 450px;
    border-radius: 8px;
}

.useful-links h2 {
    color: white;
    font-size: 20px;
    margin: 0 0 10px;
}

.useful-links p {
    margin: 6px 0;
}

.useful-links a {
    color: white;
    text-decoration: none;
    font-weight: bold;
}

.useful-links a:hover {
    color: #ffd700;
    text-decoration: underline;
}

/* Office Location */
.office-location {
    max-width: 900px;
    margin: 30px auto;
    padding: 20px;
    background-color: #ffffff;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.office-location h2 {
    color: #173d61;
    text-align: center;
    margin-bottom: 15px;
}

.office-location p {
    line-height: 1.7;
}

.office-location a {
    color: #1877F2;
    font-weight: bold;
    text-decoration: none;
}

.office-location a:hover {
    text-decoration: underline;
}

.map-container {
    width: 100%;
    overflow: hidden;
    border-radius: 8px;
    margin-top: 15px;
}

.map-container iframe {
    display: block;
    width: 100%;
    height: 350px;
    border: 0;
}

@media (max-width: 600px) {
    .office-location {
        margin: 20px 10px;
        padding: 15px;
    }

    .map-container iframe {
        height: 280px;
    }
}