/* Base Styles */
:root {
    --primary-color: #004d99;
    --secondary-color: #e74c3c;
    --accent-color: #f39c12;
    --light-color: #f8f9fa;
    --dark-color: #343a40;
    --text-color: #333333;
    --border-color: #dddddd;
    --success-color: #28a745;
    --font-primary: 'Noto Sans JP', 'Helvetica Neue', Arial, sans-serif;
    --transition: all 0.3s ease;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-primary);
    line-height: 1.6;
    color: var(--text-color);
    background-color: #ffffff;
    overflow-x: hidden;
}

.container {
    width: 90%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

section {
    padding: 80px 0;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 15px;
}

a {
    text-decoration: none;
    color: var(--primary-color);
    transition: var(--transition);
}

a:hover {
    color: var(--secondary-color);
}

ul {
    list-style: none;
}

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

.section-title {
    font-size: 2.5rem;
    text-align: center;
    margin-bottom: 50px;
    color: var(--primary-color);
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 80px;
    height: 4px;
    background-color: var(--secondary-color);
    margin: 15px auto;
}

.section-note {
    text-align: center;
    font-size: 0.9rem;
    margin-bottom: 30px;
    color: #666;
}

.sub-section-title {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin: 40px 0 20px;
    border-left: 4px solid var(--secondary-color);
    padding-left: 15px;
}

/* Header & Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: rgba(255, 255, 255, 0.95);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    transition: var(--transition);
    padding: 15px 0;
}

.navbar.scrolled {
    padding: 10px 0;
    background-color: rgba(255, 255, 255, 0.98);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-size: 1.5rem;
    color: var(--primary-color);
    margin: 0;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links li {
    margin-left: 30px;
}

.nav-links a {
    color: var(--dark-color);
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary-color);
    transition: var(--transition);
}

.nav-links a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    transition: var(--transition);
    background-color: var(--dark-color);
}

/* Hero Section */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0, 0, 0, 0.6), rgba(0, 0, 0, 0.6)), 
                url('../images/main.png');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    display: flex;
    align-items: center;
    text-align: center;
    color: #ffffff;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
}

.hero h2 {
    font-size: 3rem;
    margin-bottom: 20px;
    animation: fadeInDown 1s ease;
}

.hero p {
    font-size: 1.3rem;
    margin-bottom: 30px;
    animation: fadeInUp 1s ease 0.3s;
    animation-fill-mode: both;
}

/* About Section */
.about-text {
    width: 100%;
    margin-bottom: 30px;
}

.about-text p {
    margin-bottom: 20px;
    text-align: justify;
}

.greeting-content {
    max-width: 800px;
    margin: 0 auto;
}

.greeting-content p {
    line-height: 1.8;
    margin-bottom: 20px;
    text-align: justify;
}

.greeting-content .signature {
    text-align: right;
    font-weight: 600;
    margin-top: 30px;
}

.company-info {
    width: 100%;
    margin-bottom: 40px;
}

.company-info h3 {
    margin-bottom: 20px;
    font-size: 1.3rem;
    color: var(--primary-color);
}

.info-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 20px;
}

.info-table th, .info-table td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border-color);
    text-align: left;
}

.info-table th {
    width: 30%;
    font-weight: 600;
    color: var(--primary-color);
}

.certifications {
    display: flex;
    justify-content: center;
    margin-top: 30px;
}

.license-image h4, .license-text h4, .sdgs-image h4 {
    font-size: 1.1rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.license-text {
    border: 2px solid var(--primary-color);
    padding: 25px;
    max-width: 900px;
    width: 100%;
}

.license-text h4 {
    text-align: center;
    font-size: 1.3rem;
    margin-bottom: 20px;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
}

.license-list {
    margin-bottom: 20px;
}

.license-item {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
    margin-bottom: 15px;
    padding: 15px;
    background-color: #fafafa;
    border-left: 4px solid var(--primary-color);
}

.license-type {
    font-weight: 600;
    font-size: 1.1rem;
    color: var(--primary-color);
    flex: 0 0 auto;
    min-width: 200px;
}

.license-info {
    font-weight: 500;
    color: var(--text-color);
    flex: 1;
}

.license-date {
    font-weight: 400;
    color: #666;
    font-size: 0.95rem;
    flex: 0 0 auto;
    white-space: nowrap;
}

.auto-license {
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid var(--border-color);
    font-weight: 600;
    text-align: center;
    color: var(--primary-color);
}

.license-image img, .sdgs-image img {
    max-width: 100%;
    border: 1px solid var(--border-color);
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .certifications {
        padding: 0 15px;
    }

    .license-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .license-type {
        min-width: auto;
    }
}

/* History Timeline */
.parallax-section {
    position: relative;
    background-attachment: fixed;
    background-position: center;
    background-repeat: no-repeat;
    background-size: cover;
}

#history {
    background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), 
                      url('https://images.unsplash.com/photo-1595843803237-31a5bbf04d6c?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    color: #ffffff;
}

#history .section-title {
    color: #ffffff;
}

.timeline {
    position: relative;
    max-width: 800px;
    margin: 0 auto;
}

.timeline::after {
    content: '';
    position: absolute;
    width: 4px;
    background-color: #ffffff;
    top: 0;
    bottom: 0;
    left: 50%;
    margin-left: -2px;
}

.timeline-item {
    position: relative;
    margin-bottom: 40px;
    width: 50%;
    padding-right: 40px;
}

.timeline-item:nth-child(even) {
    left: 50%;
    padding-right: 0;
    padding-left: 40px;
}

.timeline-item::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    right: -10px;
    top: 20px;
    background-color: var(--accent-color);
    border-radius: 50%;
    z-index: 1;
}

.timeline-item:nth-child(even)::after {
    left: -10px;
}

.year {
    font-weight: 700;
    font-size: 1.1rem;
    color: var(--accent-color);
    margin-bottom: 5px;
}

.event {
    background-color: rgba(255, 255, 255, 0.1);
    padding: 15px;
    border-radius: 5px;
}

/* Products Grid */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
}

.product-item {
    background-color: #f9f9f9;
    padding: 30px 20px;
    border-radius: 5px;
    text-align: center;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
}

.product-item:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.product-icon {
    font-size: 2.5rem;
    margin-bottom: 15px;
    color: var(--primary-color);
}

.product-item h3 {
    font-size: 1rem;
    margin-bottom: 0;
}

/* Achievements Section */
#achievements {
    background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)), 
                      url('https://images.unsplash.com/photo-1504639725590-34d0984388bd?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    color: #ffffff;
}

#achievements .section-title {
    color: #ffffff;
}

.achievements-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.achievement-category {
    margin-bottom: 30px;
}

.achievement-category h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--accent-color);
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 8px;
    display: inline-block;
}

.achievement-columns {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.achievement-list li {
    margin-bottom: 10px;
    position: relative;
    padding-left: 20px;
}

.achievement-list li::before {
    content: '▶';
    position: absolute;
    left: 0;
    color: var(--accent-color);
    font-size: 0.8rem;
}

.wide-category {
    grid-column: 1 / -1;
}

@media (max-width: 768px) {
    .achievement-columns {
        grid-template-columns: 1fr;
    }
}

/* Partners Section */
.partners-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    gap: 30px;
}

.partners-list {
    flex: 1;
    min-width: 300px;
}

.partner-item {
    padding: 10px 15px;
    margin-bottom: 10px;
    background-color: #f9f9f9;
    border-radius: 5px;
    transition: var(--transition);
}

.partner-item:hover {
    background-color: var(--primary-color);
    color: #ffffff;
}

.makers-list {
    margin-bottom: 30px;
}

.makers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.maker-item {
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    transition: var(--transition);
}

.maker-item:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.maker-item h4 {
    font-size: 1.1rem;
    margin-bottom: 5px;
    color: var(--primary-color);
}

.maker-item p {
    font-size: 0.9rem;
    color: #666;
}

/* Sustainability Section */
.sustainability-subsection {
    margin-bottom: 50px;
}

.environment-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: center;
    margin-top: 30px;
}

.environment-image {
    text-align: center;
}

.environment-image img {
    max-width: 100%;
    height: auto;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    /* cursor: pointer; */
    transition: var(--transition);
}

/* .environment-image img:hover {
    transform: scale(1.05);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
} */

.environment-text h4 {
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.environment-text p {
    line-height: 1.8;
    margin-bottom: 15px;
}

.emissions-data {
    background-color: #f9f9f9;
    padding: 15px;
    border-left: 4px solid var(--primary-color);
    font-weight: 500;
}

.sustainability-flex-section {
    display: flex;
    gap: 40px;
    margin-bottom: 50px;
}

.sustainability-flex-section .sustainability-subsection {
    flex: 1;
    margin-bottom: 0;
}

.social-content {
    margin-top: 30px;
}

.social-content .sdgs-image {
    text-align: center;
}

.social-content .sdgs-image img {
    max-width: 100%;
    height: auto;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.management-content {
    margin-top: 30px;
}

.management-content .nintei-image {
    text-align: center;
}

.management-content .nintei-image img {
    max-width: 100%;
    height: auto;
    border: 2px solid var(--border-color);
    border-radius: 5px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
    .sustainability-flex-section {
        flex-direction: column;
        gap: 20px;
    }

    .social-content .sdgs-image,
    .management-content .nintei-image {
        max-width: 80%;
        margin: 0 auto;
    }
}

/* CO2削減実績テーブル */
.co2-reduction-table {
    margin: 30px 0;
    overflow-x: auto;
}

.co2-reduction-table table {
    width: 100%;
    max-width: 800px;
    margin: 0 auto;
    border-collapse: collapse;
    background-color: #ffffff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.co2-reduction-table thead {
    background-color: var(--primary-color);
    color: #ffffff;
}

.co2-reduction-table th {
    padding: 15px;
    text-align: center;
    font-weight: 600;
    font-size: 1rem;
}

.co2-reduction-table td {
    padding: 12px 15px;
    text-align: center;
    border-bottom: 1px solid var(--border-color);
}

.co2-reduction-table tbody tr:hover {
    background-color: #f9f9f9;
}

.co2-reduction-table .target-row {
    background-color: #fff3cd;
    font-weight: 600;
}

.co2-reduction-table .target-row:hover {
    background-color: #ffecb3;
}

@media (max-width: 768px) {
    .co2-reduction-table table {
        font-size: 0.9rem;
    }

    .co2-reduction-table th,
    .co2-reduction-table td {
        padding: 10px 8px;
    }
}

/* 画像モーダル */
.modal {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
}

.modal-content {
    margin: auto;
    display: block;
    max-width: 90%;
    max-height: 90%;
}

.modal-close {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.modal-close:hover,
.modal-close:focus {
    color: #bbb;
}

.sustainability-buttons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 20px;
    margin-top: 30px;
}

.sustainability-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 15px 30px;
    background-color: var(--primary-color);
    color: #ffffff;
    border-radius: 5px;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.sustainability-btn:hover {
    background-color: var(--secondary-color);
    color: #ffffff;
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.sustainability-btn i {
    font-size: 1.5rem;
}

@media (max-width: 768px) {
    .environment-content {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* Affiliates Section */
#affiliates {
    background-image: linear-gradient(rgba(0, 0, 0, 0.7), rgba(0, 0, 0, 0.7)),
                     url('https://images.unsplash.com/photo-1554646375-7a89925a5cb6?ixlib=rb-1.2.1&auto=format&fit=crop&w=1350&q=80');
    color: #ffffff;
}

#affiliates .section-title {
    color: #ffffff;
}

.affiliate-content {
    max-width: 800px;
    margin: 0 auto;
}

.affiliate-intro {
    font-size: 1.1rem;
    margin-bottom: 20px;
}

#affiliates .info-table {
    color: #ffffff;
    margin-top: 40px;
}

#affiliates .info-table th,
#affiliates .info-table td {
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

#affiliates .info-table th {
    color: var(--accent-color);
}

/* Footer */
.footer {
    background-color: var(--dark-color);
    color: #ffffff;
    padding: 60px 0 20px;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin-bottom: 30px;
}

.footer-info {
    flex: 1;
    min-width: 300px;
    margin-bottom: 30px;
}

.footer-info h3 {
    margin-bottom: 15px;
    font-size: 1.3rem;
}

.footer-info p {
    color: #aaa;
    margin-bottom: 10px;
}

.footer-nav {
    flex: 1;
    min-width: 300px;
}

.footer-nav ul {
    display: flex;
    flex-wrap: wrap;
}

.footer-nav li {
    margin-right: 20px;
    margin-bottom: 10px;
}

.footer-nav a {
    color: #aaa;
    transition: var(--transition);
}

.footer-nav a:hover {
    color: #ffffff;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #aaa;
    font-size: 0.9rem;
}

/* Scroll to Top Button */
.scroll-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    background-color: var(--primary-color);
    color: #ffffff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    opacity: 0;
    transition: var(--transition);
    z-index: 99;
}

.scroll-to-top.show {
    opacity: 1;
}

/* Animations */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Media Queries */
@media (max-width: 991px) {
    .section-title {
        font-size: 2rem;
    }
    
    .hero h2 {
        font-size: 2.5rem;
    }
    
    .timeline::after {
        left: 31px;
    }
    
    .timeline-item {
        width: 100%;
        padding-left: 70px;
        padding-right: 0;
    }
    
    .timeline-item:nth-child(even) {
        left: 0;
        padding-left: 70px;
    }
    
    .timeline-item::after,
    .timeline-item:nth-child(even)::after {
        left: 20px;
    }
}

@media (max-width: 768px) {
    .navbar {
        padding: 15px 0;
    }
    
    .nav-links {
        position: fixed;
        top: -100%;
        left: 0;
        width: 100%;
        background-color: #ffffff;
        flex-direction: column;
        box-shadow: 0 5px 10px rgba(0, 0, 0, 0.1);
        transition: 0.5s;
        padding: 20px 0;
    }
    
    .nav-links.active {
        top: 70px;
    }
    
    .nav-links li {
        margin: 15px 0;
    }
    
    .hamburger {
        display: block;
    }
    
    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }
    
    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }
    
    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }
    
    .section {
        padding: 60px 0;
    }
    
    .hero h2 {
        font-size: 2rem;
    }
    
    .hero p {
        font-size: 1.1rem;
    }
    
    .achievement-category {
        padding: 0 15px;
    }
}

@media (max-width: 576px) {
    .section-title {
        font-size: 1.8rem;
    }
    
    .hero h2 {
        font-size: 1.8rem;
    }
    
    .info-table th, .info-table td {
        padding: 10px;
    }
    
    .products-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}