@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+JP:wght@300;400;500;700&family=Outfit:wght@400;600;800&display=swap');

/* ==========================================================================
   CSS Variables & Design Tokens
   ========================================================================== */
:root {
  /* Common Colors (independent of theme) */
  --secondary-color: #f77f00; /* Warm Sun/Orange */
  --accent-color: #2a9d8f;    /* Nature/Green */
  --bg-color: #f8fafc;
  --card-bg: #ffffff;
  --text-primary: #1e293b;
  --text-secondary: #64748b;
  --text-light: #94a3b8;
  --border-color: #e2e8f0;
  
  /* Layout & Spacing */
  --header-height: 80px;
  --border-radius-sm: 8px;
  --border-radius-md: 12px;
  --border-radius-lg: 24px;
  
  /* Shadow Styles */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 20px 25px -5px rgba(0, 0, 0, 0.05), 0 10px 10px -5px rgba(0, 0, 0, 0.04);

  /* Typography Scale (Defaults to medium) */
  --font-base-size: 16px;
  --font-title-lg: 2rem;
  --font-title-md: 1.5rem;
  --font-title-sm: 1.2rem;
  --font-body: 1rem;
  --font-small: 0.875rem;
}

/* ==========================================================================
   Theme Configurations (CSS Variables)
   ========================================================================== */
/* 1. Default / Blue Theme */
:root, html[data-theme="blue"] {
  --primary-color: #0d6efd;
  --primary-dark: #0a58ca;
  --primary-light: #e7f1ff;
  --shadow-hover: 0 20px 25px -5px rgba(13, 110, 253, 0.1), 0 10px 10px -5px rgba(13, 110, 253, 0.04);
}

/* 2. Green Theme (Nature & Freshness) */
html[data-theme="green"] {
  --primary-color: #2a9d8f;
  --primary-dark: #1f7a6e;
  --primary-light: #e6f4f2;
  --shadow-hover: 0 20px 25px -5px rgba(42, 157, 143, 0.1), 0 10px 10px -5px rgba(42, 157, 143, 0.04);
}

/* 3. Orange Theme (Warm Sun & Energy) */
html[data-theme="orange"] {
  --primary-color: #f77f00;
  --primary-dark: #d66800;
  --primary-light: #fff3e6;
  --shadow-hover: 0 20px 25px -5px rgba(247, 127, 0, 0.1), 0 10px 10px -5px rgba(247, 127, 0, 0.04);
}

/* 4. Sakura Theme (Cherry Blossoms & Friendliness) */
html[data-theme="sakura"] {
  --primary-color: #e05a88;
  --primary-dark: #c03d69;
  --primary-light: #fbebf0;
  --shadow-hover: 0 20px 25px -5px rgba(224, 90, 136, 0.1), 0 10px 10px -5px rgba(224, 90, 136, 0.04);
}



/* ==========================================================================
   Reset & Base Styles
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: var(--font-base-size);
  scroll-behavior: smooth;
}

body {
  font-family: 'Noto Sans JP', 'Helvetica Neue', Arial, sans-serif;
  background-color: var(--bg-color);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: var(--primary-color);
  text-decoration: none;
  transition: color 0.25s ease, opacity 0.25s ease;
}

a:hover {
  color: var(--primary-dark);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

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

.branding {
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
}

.site-title {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--primary-dark);
  line-height: 1.2;
  white-space: nowrap;
}

.site-title a {
  color: inherit;
  white-space: nowrap;
}

.site-subtitle {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 500;
  white-space: nowrap;
}

/* Main Navigation */
.main-nav {
  display: flex;
  align-items: center;
  gap: 1rem;
  flex-shrink: 0;
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: 0.25rem;
}

.nav-link {
  font-weight: 500;
  color: var(--text-primary);
  padding: 0.4rem 0.5rem;
  border-radius: var(--border-radius-sm);
  font-size: 0.85rem;
  transition: all 0.2s ease;
  position: relative;
  white-space: nowrap;
}

.nav-link:hover, .nav-link.active {
  color: var(--primary-color);
  background-color: var(--primary-light);
}



/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-primary);
  padding: 0.5rem;
}

/* ==========================================================================
   Hero Visual Section
   ========================================================================== */
.hero-section {
  position: relative;
  height: 400px;
  background-color: #000;
  overflow: hidden;
  display: flex;
  align-items: center;
  color: #ffffff;
}

.hero-img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.9;
}

.hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 50%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.6) 0%, rgba(0, 0, 0, 0) 100%);
  z-index: 1;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 1200px;
  margin: 0 auto;
  width: 100%;
  padding: 0 1.5rem;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.hero-badge {
  display: inline-block;
  background-color: var(--secondary-color);
  color: #ffffff;
  padding: 0.35rem 1rem;
  border-radius: 50px;
  font-size: 0.85rem;
  font-weight: 700;
  margin-bottom: 1rem;
  letter-spacing: 0.05em;
  box-shadow: var(--shadow-sm);
}

.hero-title {
  font-size: var(--font-title-lg);
  font-weight: 700;
  margin-bottom: 0.5rem;
  letter-spacing: -0.02em;
}

.hero-desc {
  font-size: var(--font-title-sm);
  font-weight: 400;
  opacity: 0.9;
}

/* Quick Contact Strip */
.quick-contact-strip {
  background-color: var(--primary-dark);
  color: #ffffff;
  font-size: 0.9rem;
  padding: 0.75rem 0;
  border-bottom: 4px solid var(--secondary-color);
}

.contact-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.contact-items {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.contact-item svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
  opacity: 0.8;
}

.contact-link {
  color: #ffffff;
}

.contact-link:hover {
  text-decoration: underline;
}

.urgent-badge {
  background-color: var(--secondary-color);
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-weight: 700;
  font-size: 0.75rem;
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); opacity: 0.9; }
  100% { transform: scale(1); }
}

/* ==========================================================================
   Main Content Layout
   ========================================================================== */
.main-wrapper {
  max-width: 1200px;
  margin: 3rem auto;
  padding: 0 1.5rem;
  min-height: 50vh;
}

.page-section {
  display: none;
  animation: fadeIn 0.4s ease-out forwards;
}

.page-section.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Section Titles */
.section-header {
  border-left: 5px solid var(--primary-color);
  padding-left: 1rem;
  margin-bottom: 2rem;
  transition: border-color 0.3s ease;
}

.section-title {
  font-size: var(--font-title-lg);
  color: var(--text-primary);
  font-weight: 700;
  line-height: 1.2;
}

.section-subtitle {
  font-size: var(--font-small);
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Layout Grids */
.grid-container {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2.5rem;
}

/* ==========================================================================
   Home Section Specifics
   ========================================================================== */
.welcome-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  margin-bottom: 2.5rem;
}

.welcome-card h3 {
  font-size: var(--font-title-sm);
  color: var(--primary-dark);
  margin-bottom: 1rem;
  font-weight: 700;
}

.welcome-card p {
  color: var(--text-primary);
  margin-bottom: 1rem;
}

/* Info Cards Block */
.info-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.info-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.info-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-hover);
  border-color: var(--primary-light);
}

.info-card-title {
  font-size: var(--font-title-sm);
  color: var(--text-primary);
  font-weight: 700;
  margin-bottom: 0.75rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.info-card-title svg {
  width: 24px;
  height: 24px;
  color: var(--primary-color);
}

.info-card-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.info-card-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--primary-color);
}

.info-card-btn::after {
  content: '→';
  transition: transform 0.2s ease;
}

.info-card:hover .info-card-btn::after {
  transform: translateX(4px);
}

/* News List */
.news-widget {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.news-widget-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.75rem;
}

.news-widget-title {
  font-size: var(--font-title-sm);
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.news-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.news-item {
  display: flex;
  gap: 1.5rem;
  border-bottom: 1px dashed var(--border-color);
  padding-bottom: 1rem;
}

.news-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.news-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
  font-weight: 600;
  white-space: nowrap;
  padding-top: 0.15rem;
}

.news-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.news-title {
  font-size: 0.95rem;
  color: var(--text-primary);
  font-weight: 500;
}

.news-title a {
  color: inherit;
}

.news-title a:hover {
  color: var(--primary-color);
  text-decoration: underline;
}

.news-tag {
  display: inline-block;
  align-self: flex-start;
  font-size: 0.75rem;
  padding: 0.1rem 0.5rem;
  border-radius: 4px;
  font-weight: 600;
}

.news-tag.pdf {
  background-color: #ffeef0;
  color: #ff4757;
  border: 1px solid #ffd2d6;
}

.news-tag.info {
  background-color: var(--primary-light);
  color: var(--primary-dark);
  border: 1px solid #cce3ff;
}

/* Sidebar Widgets */
.sidebar {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

.sidebar-widget {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  padding: 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
}

.sidebar-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 1rem;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 0.5rem;
}

.btn-blog {
  display: block;
  background-color: var(--primary-color);
  color: #ffffff;
  text-align: center;
  padding: 0.85rem 1rem;
  border-radius: var(--border-radius-sm);
  font-weight: 700;
  font-size: 1rem;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

.btn-blog:hover {
  background-color: var(--primary-dark);
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ==========================================================================
   Table & List Styling
   ========================================================================== */
.school-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 1.5rem;
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
}

.school-table th, .school-table td {
  padding: 1rem 1.5rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.school-table th {
  background-color: var(--primary-light);
  color: var(--primary-dark);
  font-weight: 700;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.school-table tr:last-child td {
  border-bottom: none;
}

.school-table tr:nth-child(even) {
  background-color: var(--bg-color);
}

.school-table .total-row {
  font-weight: 700;
  background-color: var(--primary-light) !important;
  transition: background-color 0.3s ease;
}

/* History Timeline */
.timeline {
  position: relative;
  max-width: 1000px;
  margin: 2rem auto;
  padding: 1rem 0;
}

.timeline::before {
  content: '';
  position: absolute;
  top: 0;
  bottom: 0;
  left: 120px;
  width: 3px;
  background-color: var(--primary-light);
  border-radius: 5px;
}

.timeline-item {
  position: relative;
  display: flex;
  margin-bottom: 2rem;
}

.timeline-year {
  width: 110px;
  flex-shrink: 0;
  text-align: right;
  font-weight: 700;
  color: var(--primary-dark);
  font-size: 1.1rem;
  padding-top: 0.25rem;
  font-family: 'Outfit', sans-serif;
  white-space: nowrap;
}

.timeline-marker {
  position: absolute;
  left: 121px;
  top: 8px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background-color: #ffffff;
  border: 4px solid var(--primary-color);
  z-index: 10;
  transform: translateX(-50%);
  transition: background-color 0.3s ease, border-color 0.3s ease;
}

.timeline-item:hover .timeline-marker {
  background-color: var(--secondary-color);
  border-color: var(--secondary-color);
}

.timeline-content {
  margin-left: 50px;
  background-color: var(--card-bg);
  border-radius: var(--border-radius-sm);
  padding: 1rem 1.5rem;
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  flex-grow: 1;
}

/* Event List Accordion-style Card */
.event-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1.5rem;
}

.event-month-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
}

.event-month-header {
  background-color: var(--primary-color);
  color: #ffffff;
  padding: 0.75rem 1.5rem;
  font-size: 1.1rem;
  font-weight: 700;
  font-family: 'Outfit', sans-serif;
  display: flex;
  justify-content: space-between;
  align-items: center;
  transition: background-color 0.3s ease;
}

.event-month-body {
  padding: 1.5rem;
  font-size: 0.95rem;
  color: var(--text-primary);
  min-height: 100px;
}

/* Documents / School Letter Section Layout */
.letter-section-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 2rem;
  margin-top: 1.5rem;
}

.letter-selector {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.letter-select-btn {
  background-color: var(--card-bg);
  border: 1px solid var(--border-color);
  padding: 1rem 1.25rem;
  border-radius: var(--border-radius-md);
  text-align: left;
  font-weight: 600;
  font-size: 1.15rem;
  color: var(--text-primary);
  cursor: pointer;
  transition: all 0.2s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-shadow: var(--shadow-sm);
}

.letter-select-btn:hover {
  background-color: var(--primary-light);
  border-color: var(--primary-color);
  color: var(--primary-dark);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.letter-select-btn.active {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: #ffffff;
}

.letter-select-btn .arrow-icon {
  font-size: 1.2rem;
  opacity: 0.7;
}

.letter-select-btn.active .arrow-icon {
  transform: translateX(3px);
  opacity: 1;
}

.letter-preview-area {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  min-height: 700px;
}

.letter-preview-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  border-bottom: 2px solid var(--border-color);
  padding-bottom: 1rem;
}

.letter-preview-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
}

.pdf-embed-container {
  flex-grow: 1;
  border: 1px solid var(--border-color);
  border-radius: var(--border-radius-sm);
  overflow: hidden;
  height: 600px;
  background-color: #f1f5f9;
  position: relative;
}

.pdf-embed-container iframe {
  width: 100%;
  height: 100%;
  border: none;
}

@media (max-width: 992px) {
  .letter-section-layout {
    grid-template-columns: 1fr;
  }
  .letter-preview-area {
    min-height: auto;
  }
}

@media (max-width: 768px) {
  .pdf-embed-container {
    display: none;
  }
}

/* Bulletins Section Custom Styling */
.bulletin-box {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
  text-align: center;
  max-width: 700px;
  margin: 0 auto;
}

.bulletin-title {
  font-size: var(--font-title-sm);
  margin-bottom: 1.5rem;
  color: var(--text-primary);
}

.btn-large-pdf {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  background-color: #ff4757;
  color: #ffffff;
  padding: 1rem 2rem;
  border-radius: var(--border-radius-sm);
  font-weight: 700;
  font-size: 1.1rem;
  box-shadow: 0 4px 15px rgba(255, 71, 87, 0.3);
  transition: all 0.2s ease;
}

.btn-large-pdf:hover {
  background-color: #ff2a3a;
  color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(255, 71, 87, 0.4);
}

.btn-large-pdf svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

/* ==========================================================================
   Access & Map Styling
   ========================================================================== */
.access-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2.5rem;
}

.map-container {
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  height: 400px;
}

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

.access-info-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.info-item {
  display: flex;
  gap: 1rem;
}

.info-icon {
  color: var(--primary-color);
  flex-shrink: 0;
  padding-top: 0.2rem;
}

.info-icon svg {
  width: 24px;
  height: 24px;
  fill: currentColor;
}

.info-text h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.info-text p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* ==========================================================================
   Footer
   ========================================================================== */
.site-footer {
  background-color: #1e293b;
  color: #e2e8f0;
  padding: 4rem 0 2rem;
  margin-top: 5rem;
  border-top: 4px solid var(--primary-color);
  transition: border-top-color 0.3s ease;
}

.footer-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem;
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

.footer-branding {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
}

.footer-subtitle {
  font-size: 0.85rem;
  color: #94a3b8;
}

.footer-address {
  font-style: normal;
  margin-top: 1rem;
  font-size: 0.95rem;
  color: #cbd5e1;
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.footer-links-widget {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.footer-links-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
}

.footer-menu {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-menu-link {
  color: #94a3b8;
  font-size: 0.95rem;
}

.footer-menu-link:hover {
  color: #ffffff;
  text-decoration: underline;
}

.footer-bottom {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem 0;
  border-top: 1px solid #334155;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
}

.copyright {
  font-size: 0.85rem;
  color: #64748b;
}

/* ==========================================================================
   Responsive Utilities (Mobile & Tablet)
   ========================================================================== */
@media (max-width: 992px) {
  .grid-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .access-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .timeline::before {
    left: 20px;
  }
  
  .timeline-year {
    width: 60px;
    text-align: left;
    padding-left: 35px;
    font-size: 0.95rem;
  }
  
  .timeline-marker {
    left: 21px;
  }
  
  .timeline-content {
    margin-left: 20px;
    padding: 0.75rem 1rem;
  }
}

@media (min-width: 1101px) and (max-width: 1250px) {
  .site-title {
    font-size: 1.2rem;
  }
  .site-subtitle {
    display: none;
  }
  .nav-link {
    font-size: 0.85rem;
    padding: 0.4rem 0.45rem;
  }
}

@media (max-width: 1100px) {
  .site-header {
    height: 60px;
  }

  .header-container {
    height: 100%;
    padding: 0 1rem;
    flex-wrap: nowrap;
    gap: 1rem;
  }

  .site-title {
    font-size: 1.15rem;
  }

  .site-subtitle {
    display: none;
  }

  .menu-toggle {
    display: block;
    z-index: 210;
  }

  .main-nav {
    display: flex;
    position: fixed;
    top: 0;
    right: 0;
    height: 100vh;
    width: 80%;
    max-width: 280px;
    background-color: var(--card-bg);
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.1);
    padding: 5rem 1.5rem 2rem;
    z-index: 200;
    flex-direction: column;
    align-items: stretch;
    gap: 1.5rem;
    overflow-y: auto;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.3s ease, visibility 0.3s ease;
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
  }

  .main-nav.open {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-menu {
    flex-direction: column;
    gap: 0.75rem;
  }

  .nav-link {
    font-size: 1.05rem;
    padding: 0.6rem 1rem;
    display: block;
  }
}

@media (max-width: 768px) {
  .hero-section {
    height: 300px;
  }

  .hero-title {
    font-size: 1.5rem;
  }

  .hero-desc {
    font-size: 1rem;
  }

  .contact-container {
    flex-direction: column;
    align-items: flex-start;
  }
  
  .footer-container {
    grid-template-columns: 1fr;
    gap: 2rem;
  }

  .footer-bottom {
    flex-direction: column;
    text-align: center;
  }
}

/* --- New Photo Gallery Section --- */
.gallery-section {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  border: 1px solid var(--border-color);
  padding: 2.5rem;
  box-shadow: var(--shadow-sm);
  margin-top: 3rem;
}

.gallery-section-header {
  text-align: center;
  margin-bottom: 2rem;
}

.gallery-section-title {
  font-size: var(--font-title-sm);
  font-weight: 700;
  color: var(--primary-dark);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.gallery-section-title svg {
  color: var(--primary-color);
}

.gallery-section-subtitle {
  font-size: 0.95rem;
  color: var(--text-secondary);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.5rem;
}

/* Gallery Item Hover Overlay Effects */
.gallery-item {
  position: relative;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  aspect-ratio: 4 / 3;
  cursor: pointer;
  background-color: #f0f0f0;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

/* ホバー時に画像を拡大 */
.gallery-item:hover img {
  transform: scale(1.08);
}

/* ホバー時の高級感ある暗転 */
.gallery-item::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.5) 0%, rgba(0,0,0,0.1) 70%, rgba(0,0,0,0) 100%);
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

/* ホバーでオーバーレイをフェードイン */
.gallery-item:hover::after {
  opacity: 1;
}

/* 「詳細を見る」ラベルのホバー表示 */
.gallery-item-overlay-text {
  position: absolute;
  bottom: 1rem;
  left: 50%;
  transform: translate(-50%, 20px);
  background-color: rgba(255, 255, 255, 0.9);
  color: var(--primary-dark);
  padding: 0.4rem 1rem;
  border-radius: 30px;
  font-size: 0.8rem;
  font-weight: 700;
  opacity: 0;
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  box-shadow: var(--shadow-md);
  white-space: nowrap;
  pointer-events: none;
  z-index: 2;
}

.gallery-item:hover .gallery-item-overlay-text {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* --- Lightbox Modal --- */
.lightbox-modal {
  display: none;
  position: fixed;
  z-index: 9999;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px) saturate(180%);
  -webkit-backdrop-filter: blur(12px) saturate(180%);
  justify-content: space-between;
  align-items: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.lightbox-modal.active {
  display: flex;
  opacity: 1;
}

.lightbox-content-wrapper {
  max-width: 80%;
  max-height: 80%;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.lightbox-content {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
  border-radius: var(--border-radius-md);
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.lightbox-modal.active .lightbox-content {
  transform: scale(1);
}

.lightbox-caption {
  margin-top: 1rem;
  color: #ffffff;
  font-size: 1rem;
  text-align: center;
  background-color: rgba(0, 0, 0, 0.6);
  padding: 0.5rem 1.5rem;
  border-radius: 20px;
  max-width: 100%;
  box-shadow: var(--shadow-sm);
}

/* Buttons */
.lightbox-close {
  position: absolute;
  top: 2rem;
  right: 2rem;
  color: #ffffff;
  font-size: 2.5rem;
  font-weight: 300;
  cursor: pointer;
  transition: transform 0.2s, color 0.2s;
  width: 50px;
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: rgba(255, 255, 255, 0.1);
  border-radius: 50%;
  z-index: 10001;
}

.lightbox-close:hover {
  color: #ff4757;
  transform: scale(1.1) rotate(90deg);
  background-color: rgba(255, 255, 255, 0.2);
}

.lightbox-nav-btn {
  color: #ffffff;
  font-size: 3rem;
  font-weight: bold;
  cursor: pointer;
  user-select: none;
  transition: all 0.2s;
  padding: 1.5rem;
  margin: 0 1.5rem;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 50%;
  width: 70px;
  height: 70px;
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
}

.lightbox-nav-btn:hover {
  color: var(--primary-color);
  background-color: rgba(255, 255, 255, 0.15);
  transform: scale(1.1);
}

/* Responsive adjustments */
@media (max-width: 768px) {
  .lightbox-nav-btn {
    font-size: 2rem;
    padding: 0.5rem;
    margin: 0 0.5rem;
    width: 50px;
    height: 50px;
  }
  .lightbox-content-wrapper {
    max-width: 90%;
  }
  .lightbox-close {
    top: 1rem;
    right: 1rem;
  }
}

/* --- Homepage Redesign / Premium Styles --- */

/* 1. Welcome Banner */
.welcome-banner {
  background: linear-gradient(135deg, var(--primary-light) 0%, rgba(255,255,255,0.8) 100%);
  border-radius: var(--border-radius-md);
  border: 1px solid rgba(0, 102, 204, 0.1);
  padding: 2.5rem 2rem;
  margin-bottom: 3rem;
  box-shadow: var(--shadow-sm);
  text-align: center;
  position: relative;
  overflow: hidden;
}

.welcome-banner::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -30%;
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(0,102,204,0.05) 0%, transparent 70%);
  pointer-events: none;
}

.welcome-banner h3 {
  font-size: 1.5rem;
  color: var(--primary-dark);
  font-weight: 800;
  margin-bottom: 1rem;
  letter-spacing: 0.05em;
}

#welcome-desc {
  font-size: 1.05rem;
  line-height: 1.8;
  color: var(--text-primary);
  max-width: 800px;
  margin: 0 auto;
}

/* 2. News Item Modern Card and Hover Effects */
.news-widget {
  padding: 2.5rem;
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.02);
}

.news-item {
  border-bottom: none;
  padding: 1.25rem;
  margin-bottom: 0.75rem;
  border-radius: var(--border-radius-md);
  background-color: var(--bg-color);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  border: 1px solid transparent;
}

.news-item:hover {
  background-color: #ffffff;
  border-color: rgba(0, 102, 204, 0.15);
  transform: translateY(-3px) scale(1.01);
  box-shadow: var(--shadow-md);
}

.news-date {
  font-family: 'Outfit', sans-serif;
  color: var(--primary-dark);
}

/* 3. School Blog Banner Widget */
.blog-banner-widget {
  position: relative;
  background-image: url('../contents/img2/1.jpg'); /* 学校の画像を背景に設定 */
  background-size: cover;
  background-position: center;
  border-radius: var(--border-radius-md);
  overflow: hidden;
  padding: 0;
  height: 250px;
  box-shadow: var(--shadow-md);
  border: none;
}

.blog-banner-overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(135deg, rgba(0, 51, 102, 0.85) 0%, rgba(0, 102, 204, 0.7) 100%);
  z-index: 1;
}

.blog-banner-content {
  position: relative;
  z-index: 2;
  padding: 2rem;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  color: #ffffff;
}

.blog-banner-title {
  font-size: 1.35rem;
  font-weight: 800;
  border-bottom: none;
  padding-bottom: 0;
  color: #ffffff;
  margin: 0;
}

.blog-banner-desc {
  font-size: 0.9rem;
  line-height: 1.6;
  opacity: 0.9;
  margin: 1rem 0;
}

.btn-blog-banner {
  display: inline-block;
  background: linear-gradient(135deg, #ff7b00 0%, #ff4500 100%);
  color: #ffffff;
  text-align: center;
  padding: 0.8rem 1.5rem;
  border-radius: 30px;
  font-weight: 700;
  font-size: 0.95rem;
  box-shadow: 0 4px 15px rgba(255, 69, 0, 0.4);
  transition: all 0.3s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  align-self: flex-start;
  text-decoration: none;
}

.btn-blog-banner:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 20px rgba(255, 69, 0, 0.6);
  background: linear-gradient(135deg, #ff9100 0%, #ff5500 100%);
  color: #ffffff;
}

/* 4. Contact Widget (お問い合わせ) */
.contact-widget {
  padding: 2rem;
  border-left: 4px solid var(--primary-color); /* 左に太めのアクセント線 */
}

.contact-info-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.contact-info-list li {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.contact-info-list li svg {
  color: var(--primary-color);
  flex-shrink: 0;
  margin-top: 0.25rem;
}

.contact-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 0.15rem;
}

.contact-value {
  font-size: 0.95rem;
  color: var(--text-primary);
  line-height: 1.5;
  font-weight: 500;
}

.contact-value a {
  color: inherit;
  font-weight: 600;
}

.contact-value a:hover {
  color: var(--primary-color);
}

/* 5. Quick Navigation Section */
.quick-nav-section {
  margin-top: 4rem;
  text-align: center;
}

.quick-nav-section-title {
  font-size: var(--font-title-sm);
  color: var(--primary-dark);
  font-weight: 800;
  margin-bottom: 2rem;
  position: relative;
  display: inline-block;
  padding-bottom: 0.5rem;
}

.quick-nav-section-title::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 25%;
  width: 50%;
  height: 3px;
  background-color: var(--primary-color);
  border-radius: 2px;
}

.quick-nav-section .info-cards-grid {
  margin-bottom: 0;
}

.info-card {
  background-color: var(--card-bg);
  border-radius: var(--border-radius-md);
  padding: 2.5rem 2rem;
  border: 1px solid var(--border-color);
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.01);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  transition: all 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  text-decoration: none;
  color: inherit;
}

.info-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(0, 102, 204, 0.2);
}

.info-card * {
  pointer-events: none;
}

.info-card-icon {
  background-color: var(--primary-light);
  color: var(--primary-color);
  width: 70px;
  height: 70px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
  transition: all 0.35s;
}

.info-card:hover .info-card-icon {
  background-color: var(--primary-color);
  color: #ffffff;
  transform: scale(1.1) rotate(5deg);
}

.info-card-name {
  font-size: 1.2rem;
  color: var(--primary-dark);
  font-weight: 800;
  margin-bottom: 1rem;
}

.info-card-desc {
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-secondary);
  margin-bottom: 1.5rem;
  flex-grow: 1;
}

.info-card-btn-modern {
  display: inline-block;
  border: 1px solid var(--primary-color);
  color: var(--primary-color);
  padding: 0.6rem 1.75rem;
  border-radius: 20px;
  font-size: 0.9rem;
  font-weight: 700;
  transition: all 0.25s;
  text-decoration: none;
  background-color: transparent;
}

.info-card-btn-modern:hover {
  background-color: var(--primary-color);
  color: #ffffff;
  box-shadow: 0 4px 10px rgba(0, 102, 204, 0.2);
}


