html {
scroll-behavior: smooth;
}

body {
margin: 0;
font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
color: #333;
background: #f7fbff;
}

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

/* header */

.header {
position: fixed;
top: 0;
width: 100%;
background: #1f5fbf;
color: #fff;
z-index: 1000;
transition: height 0.3s ease, box-shadow 0.3s ease;
}

.header-inner {
display: flex;
align-items: center;
justify-content: space-between;
height: 64px;
position: relative;
transition: height 0.3s ease;
}

.header.shrink {
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.header.shrink .header-inner {
height: 52px;
}

.header.shrink .logo img {
height: 28px;
}

/* logo */

.logo {
flex-shrink: 0;
min-width: 0;
}

.logo a {
display: flex;
align-items: center;
gap: 10px;
color: #fff;
text-decoration: none;
min-width: 0;
}

.logo img {
height: 36px;
width: auto;
transition: height 0.3s ease;
flex-shrink: 0;
}

.logo h2 {
margin: 0;
font-size: 18px;
font-weight: 700;
line-height: 1.2;
color: #fff;
white-space: nowrap;
}

/* nav */

.nav {
margin-left: auto;
}

.nav ul {
display: flex;
align-items: center;
gap: 32px;
margin: 0;
padding: 0;
list-style: none;
}

.nav li {
margin: 0;
padding: 0;
}

.nav a {
display: flex;
flex-direction: column;
align-items: center;
color: #fff;
text-decoration: none;
transition: opacity 0.2s ease;
}

.nav a:hover {
opacity: 0.7;
}

.nav-en {
display: block;
font-size: 16px;
font-weight: 700;
line-height: 1.2;
text-align: center;
white-space: nowrap;
}

.nav-ja {
display: block;
margin-top: 2px;
font-size: 12px;
line-height: 1.2;
text-align: center;
opacity: 0.85;
}

/* hero */

.hero {
padding-top: 90px;
padding-bottom: 30px;
background: linear-gradient(#e7f0ff, #f7fbff);
text-align: center;
}

.hero h1 {
margin: 0 0 10px;
font-size: 42px;
line-height: 1.15;
color: #1f5fbf;
}

.hero p {
margin: 0;
line-height: 1.8;
}

/* CoC hero */

.page-coc .coc-hero {
padding-top: 90px;
padding-bottom: 30px;
}

.page-coc .coc-hero h1 {
margin: 0 0 10px;
font-size: 42px;
line-height: 1.15;
font-weight: 700;
color: #1f5fbf;
}

.page-coc .coc-hero p {
margin: 0;
line-height: 1.8;
}

/* section */

.section {
padding: 80px 0;
}

.alt {
background: #eef4ff;
}

.section-title {
border-bottom: 1px solid #ddd;
padding-bottom: 8px;
margin-bottom: 28px;
}

/* heading hierarchy */

.section h2 {
margin: 0 0 20px;
font-size: 30px;
font-weight: 700;
line-height: 1.3;
letter-spacing: 0.01em;
color: #1f5fbf;
}

.section h3 {
margin: 32px 0 12px;
font-size: 22px;
font-weight: 700;
line-height: 1.4;
color: #1f5fbf;
}

.section.alt h1 {
margin: 0 0 10px;
font-size: 42px;
line-height: 1.15;
font-weight: 700;
color: #1f5fbf;
}

.section p {
margin-bottom: 20px;
line-height: 1.8;
}

.section p a {
color: #1f5fbf;
text-decoration: none;
transition: opacity 0.2s ease;
}

.section p a:hover {
opacity: 0.7;
}

.section ul {
margin: 0;
padding-left: 20px;
}

.section li {
margin-bottom: 10px;
line-height: 1.7;
}

/* section heading */

.section-heading {
margin-bottom: 32px;
}

.section-heading-center {
text-align: center;
}

.section-kicker {
margin: 0 0 10px;
font-size: 13px;
font-weight: 700;
letter-spacing: 0.12em;
text-transform: uppercase;
color: #5a6f95;
}

.section-heading .network-lead {
max-width: 720px;
margin: 0 auto;
color: #4b5563;
}

/* community */

.notice {
margin-top: 40px;
}

.notice h3 {
margin-bottom: 12px;
}

/* events */

#event-list {
display: grid;
grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
gap: 20px;
}

.event-card {
display: flex;
align-items: center;
gap: 16px;
padding: 20px;
background: #fff;
color: #333;
text-decoration: none;
border-radius: 10px;
box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
transition: transform 0.2s ease;
}

.event-card:hover {
transform: translateY(-4px);
}

.event-image {
width: 100%;
height: 160px;
margin-bottom: 10px;
object-fit: cover;
border-radius: 10px;
}

.event-badge {
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
width: 70px;
height: 70px;
background: #1f5fbf;
color: #fff;
border-radius: 8px;
font-weight: 700;
flex-shrink: 0;
}

.event-month {
font-size: 12px;
letter-spacing: 1px;
}

.event-day {
font-size: 22px;
}

.event-title {
font-size: 16px;
font-weight: 600;
line-height: 1.4;
}

.event-meta {
font-size: 14px;
color: #666;
}

/* network */

.network-container {
max-width: 1160px;
}

.network-lead {
text-align: center;
line-height: 1.8;
}

.network-grid {
display: grid;
grid-template-columns: repeat(3, minmax(0, 1fr));
gap: 20px;
align-items: stretch;
}

.network-card {
display: block;
background: #fff;
border: 1px solid rgba(31, 95, 191, 0.08);
border-radius: 18px;
overflow: hidden;
text-decoration: none;
color: inherit;
box-shadow: 0 8px 24px rgba(31, 95, 191, 0.06);
transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}

.network-card:hover {
transform: translateY(-6px);
box-shadow: 0 16px 34px rgba(31, 95, 191, 0.13);
border-color: rgba(31, 95, 191, 0.18);
}

.network-image {
aspect-ratio: 360 / 202;
display: flex;
align-items: center;
justify-content: center;
padding: 16px;
border-bottom: 1px solid rgba(31, 95, 191, 0.06);
}

.network-image img {
max-width: 72%;
max-height: 72%;
object-fit: contain;
filter: drop-shadow(0 6px 12px rgba(0, 0, 0, 0.10));
transition: transform 0.3s ease, filter 0.3s ease;
}

.network-card:hover .network-image img {
transform: translateY(-2px) scale(1.04);
filter: drop-shadow(0 10px 18px rgba(0, 0, 0, 0.14));
}

.network-body {
padding: 14px 16px 16px;
text-align: center;
}

.network-body h3 {
margin: 0 0 6px;
font-size: 16px;
line-height: 1.35;
color: #1f5fbf;
}

.network-body p {
margin: 0;
font-size: 13px;
line-height: 1.6;
color: #5f6b7a;
}

.theme-tokyo .network-image {
background: linear-gradient(180deg, #fff8fb 0%, #fff2f6 100%);
}

.theme-kyoto .network-image {
background: linear-gradient(180deg, #fcfbf6 0%, #f7f4ea 100%);
}

.theme-okinawa .network-image {
background: linear-gradient(180deg, #fff7fb 0%, #fff0f6 100%);
}

.theme-pycon .network-image {
background: linear-gradient(180deg, #ffffff 0%, #f7f8fb 100%);
}

.theme-pyconmini .network-image {
background: linear-gradient(180deg, #f4fbff 0%, #e7f3ff 100%);
}

/* social */

.sns-links {
display: flex;
flex-wrap: wrap;
gap: 20px;
}

.sns-card {
display: inline-flex;
align-items: center;
justify-content: center;
gap: 10px;
padding: 10px 22px;
border: 2px solid #1f5fbf;
border-radius: 999px;
background: #fff;
color: #1f5fbf;
font-weight: 600;
text-decoration: none;
transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.sns-card:hover {
background: #1f5fbf;
color: #fff;
transform: translateY(-2px);
}

.sns-card span {
line-height: 1;
}

.sns-card i {
font-size: 18px;
}

.connpass-link {
border-color: #e65425;
color: #e65425;
gap: 8px;
}

.connpass-link:hover {
background: #fff7f3;
color: #e65425;
transform: translateY(-2px);
}

.connpass-link img {
width: 26px;
height: auto;
display: block;
flex-shrink: 0;
}

/* button */

.button,
.button:visited,
.button:hover,
.button:active {
color: #fff;
text-decoration: none;
}

.button {
display: inline-flex;
align-items: center;
justify-content: center;
margin-top: 20px;
padding: 14px 26px;
background: #1f5fbf;
color: #fff;
font-weight: 700;
text-decoration: none;
border-radius: 30px;
transition: background 0.2s ease, transform 0.2s ease;
white-space: nowrap;
}

.button:hover {
background: #174fa3;
transform: translateY(-2px);
}

/* footer */

footer {
padding: 30px;
text-align: center;
background: #1f5fbf;
color: #fff;
}

/* hamburger */

.menu-toggle {
display: none;
margin-left: auto;
padding: 8px;
background: none;
border: none;
color: #fff;
font-size: 32px;
cursor: pointer;
flex-shrink: 0;
border-radius: 10px;
transition: background 0.2s ease;
}

.menu-toggle:hover {
background: rgba(255, 255, 255, 0.08);
}

.menu-toggle i {
pointer-events: none;
}

/* responsive */

@media (max-width: 1100px) {
.container {
max-width: 100%;
padding: 0 20px;
}

.nav ul {
gap: 24px;
}

.nav-en {
font-size: 15px;
}

.network-grid {
grid-template-columns: repeat(2, minmax(0, 1fr));
}
}

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

.header-inner {
height: 64px;
}

.logo a {
gap: 8px;
padding: 0;
}

.logo img {
height: 30px;
width: auto;
}

.logo h2 {
font-size: clamp(14px, 4.8vw, 20px);
white-space: nowrap;
}

.menu-toggle {
display: block;
font-size: 36px;
padding: 6px 8px;
}

.nav {
display: none;
position: absolute;
top: 64px;
right: 12px;
left: auto;
width: min(88vw, 320px);
margin-left: 0;
background: #eef4ff;
border-radius: 16px;
box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
overflow: hidden;
z-index: 1001;
border: 1px solid rgba(31, 95, 191, 0.12);
}

.header.shrink .nav {
top: 52px;
}

.nav.open {
display: block;
}

.nav ul {
flex-direction: column;
align-items: stretch;
gap: 0;
}

.nav li {
position: relative;
border-bottom: 1px solid rgba(31, 95, 191, 0.1);
}

.nav li:last-child {
border-bottom: none;
}

.nav a {
position: relative;
align-items: flex-start;
padding: 12px 16px 12px 18px;
color: #1f5fbf;
background: #eef4ff;
opacity: 1;
transition: background 0.2s ease, transform 0.2s ease;
}

.nav a::before {
content: "";
position: absolute;
left: 0;
top: 10px;
bottom: 10px;
width: 4px;
background: transparent;
border-radius: 0 4px 4px 0;
transition: background 0.2s ease;
}

.nav a::after {
content: "›";
position: absolute;
right: 14px;
top: 50%;
transform: translateY(-50%);
font-size: 18px;
font-weight: 700;
color: rgba(31, 95, 191, 0.55);
transition: color 0.2s ease, transform 0.2s ease;
}

.nav a:hover {
background: #dbe8ff;
opacity: 1;
transform: none;
}

.nav a:hover::before {
background: #1f5fbf;
}

.nav a:hover::after {
color: #1f5fbf;
transform: translateY(-50%) translateX(2px);
}

.nav-en {
font-size: 15px;
font-weight: 700;
text-align: left;
white-space: normal;
line-height: 1.3;
color: #1f5fbf;
padding-right: 20px;
}

.nav-ja {
margin-top: 2px;
font-size: 12px;
text-align: left;
line-height: 1.35;
color: #5a6f95;
opacity: 1;
padding-right: 20px;
}

.hero {
padding-top: 76px;
padding-bottom: 24px;
}

.hero h1 {
font-size: clamp(28px, 10vw, 42px);
line-height: 1.15;
}

.hero p {
line-height: 1.7;
}

.page-coc .coc-hero {
padding-top: 110px;
padding-bottom: 24px;
}

.page-coc .coc-hero h1 {
font-size: clamp(28px, 10vw, 42px);
line-height: 1.15;
margin-bottom: 8px;
}

.page-coc .coc-hero p {
line-height: 1.7;
}

.section {
padding: 48px 0;
}

.section h2 {
font-size: 24px;
margin-bottom: 16px;
line-height: 1.3;
}

.section h3 {
margin: 24px 0 10px;
font-size: 18px;
line-height: 1.35;
}

.section.alt h1 {
font-size: clamp(28px, 10vw, 42px);
line-height: 1.15;
margin-bottom: 8px;
}

.section p {
margin-bottom: 16px;
line-height: 1.7;
}

.section li {
margin-bottom: 8px;
}

.section-title {
margin-bottom: 24px;
padding-bottom: 8px;
}

.section-heading {
margin-bottom: 28px;
}

.section-kicker {
font-size: 12px;
margin-bottom: 8px;
}

.notice {
margin-top: 28px;
}

.button {
font-size: 14px;
padding: 12px 20px;
border-radius: 24px;
white-space: normal;
max-width: 90%;
margin-left: auto;
margin-right: auto;
line-height: 1.4;
}

.section .button {
margin-left: auto;
margin-right: auto;
display: block;
text-align: center;
}

.sns-links {
display: flex;
flex-direction: column;
align-items: center;
gap: 12px;
}

.sns-card {
width: min(100%, 280px);
min-height: unset;
padding: 10px 16px;
}

.connpass-link img {
width: 20px;
}

.event-card {
padding: 16px;
gap: 12px;
}

.event-badge {
width: 60px;
height: 60px;
}

.event-day {
font-size: 20px;
}

.network-grid {
grid-template-columns: 1fr;
gap: 18px;
}

.network-image {
padding: 16px;
}

.network-image img {
max-width: 74%;
max-height: 74%;
}

.network-body {
padding: 14px 14px 16px;
}

.network-body h3 {
font-size: 16px;
}

.network-body p {
font-size: 13px;
line-height: 1.6;
}

footer {
padding: 24px 16px;
}
}