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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Helvetica Neue', 'Noto Sans JP', Arial, sans-serif;
    background-color: #000000;
    color: #ffffff;
    overflow-x: hidden;
    position: relative;
}

/* 稲妻背景 */
.lightning-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
    background: linear-gradient(180deg, #000000 0%, #1a0000 50%, #000000 100%);
}

#lightningCanvas {
    width: 100%;
    height: 100%;
    position: absolute;
    top: 0;
    left: 0;
}

.lightning-strikes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.glow-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle at 50% 50%, transparent 0%, rgba(0,0,0,0.4) 100%);
    pointer-events: none;
}

/* グローアニメーション */
@keyframes glowPulse {
    0%, 100% {
        filter: brightness(1) drop-shadow(0 0 20px rgba(255,0,0,0.5));
    }
    50% {
        filter: brightness(1.2) drop-shadow(0 0 40px rgba(255,0,0,0.8));
    }
}

@keyframes glowMove {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* ヘッダー */
.main-header {
    position: fixed;
    top: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.9);
    backdrop-filter: blur(20px);
    z-index: 1000;
    border-bottom: 1px solid rgba(255, 0, 0, 0.2);
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.logo {
    height: 50px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    filter: drop-shadow(0 0 10px rgba(255, 0, 0, 0.3));
    transition: filter 0.3s;
}

.logo:hover {
    filter: drop-shadow(0 0 20px rgba(255, 0, 0, 0.6));
}

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

.nav-link {
    color: #ffffff;
    text-decoration: none;
    position: relative;
    transition: color 0.3s;
    font-size: 1rem;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(90deg, #ff0000, #8b0000);
    transition: width 0.3s;
}

.nav-link:hover {
    color: #ff4444;
}

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

/* ヒーローセクション */
.hero-section {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 4rem 2rem;
}

.lightning-decoration {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        repeating-linear-gradient(
            75deg,
            transparent,
            transparent 20px,
            rgba(255,0,0,0.02) 20px,
            rgba(255,0,0,0.02) 22px,
            transparent 22px,
            transparent 40px,
            rgba(139,0,0,0.03) 40px,
            rgba(139,0,0,0.03) 41px
        );
    pointer-events: none;
    animation: lightningFlicker 0.1s infinite;
}

@keyframes lightningFlicker {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; }
}

.hero-content {
    text-align: center;
    z-index: 1;
}

.hero-title {
    font-size: 4rem;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.glow-text {
    display: inline-block;
    background: linear-gradient(90deg, #ff0000, #8b0000, #ff0000);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: glowMove 3s linear infinite;
    text-shadow: 0 0 40px rgba(255,0,0,0.5);
}

.lightning-text {
    position: relative;
    display: inline-block;
    background: linear-gradient(90deg, #ffffff, #ff0000, #8b0000, #ff0000, #ffffff);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: lightningText 0.1s infinite;
}

.lightning-text::before,
.lightning-text::after {
    content: attr(data-text);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.lightning-text::before {
    background: linear-gradient(45deg, 
        transparent 30%, 
        rgba(255,255,255,0.8) 35%, 
        rgba(255,0,0,0.9) 40%, 
        transparent 45%,
        transparent 55%,
        rgba(255,255,255,0.8) 60%,
        rgba(139,0,0,0.9) 65%,
        transparent 70%);
    background-size: 200% 200%;
    animation: lightningCrawl 2s linear infinite;
    z-index: 2;
}

.lightning-text::after {
    background: linear-gradient(-45deg,
        transparent 30%,
        rgba(255,0,0,0.6) 33%,
        transparent 36%,
        transparent 64%,
        rgba(139,0,0,0.6) 67%,
        transparent 70%);
    background-size: 200% 200%;
    animation: lightningCrawl 2.5s linear infinite reverse;
    z-index: 1;
}

@keyframes lightningText {
    0%, 95%, 100% {
        filter: brightness(1) contrast(1);
    }
    96%, 98% {
        filter: brightness(1.5) contrast(1.2);
    }
    97%, 99% {
        filter: brightness(2) contrast(1.5);
    }
}

@keyframes lightningCrawl {
    0% {
        background-position: -100% -100%;
    }
    100% {
        background-position: 200% 200%;
    }
}

.hero-subtitle {
    font-size: 1.3rem;
    color: #cccccc;
    margin-bottom: 2rem;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: linear-gradient(135deg, #ff0000, #8b0000);
    color: #ffffff;
    text-decoration: none;
    border-radius: 30px;
    font-weight: bold;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.cta-button::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(255,0,0,0.4);
}

.cta-button:hover::before {
    left: 100%;
}

/* セクション共通 */
.services-section,
.business-section,
.contact-section {
    padding: 5rem 2rem;
    position: relative;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.section-title {
    font-size: 3rem;
    text-align: center;
    margin-bottom: 3rem;
}

.title-glow {
    background: linear-gradient(90deg, #ff0000, #8b0000, #ff0000);
    background-size: 200% 100%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    animation: glowMove 3s linear infinite;
}

/* サービスセクション */
.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 3rem;
}

.service-card {
    background: rgba(20, 0, 0, 0.8);
    border: 1px solid rgba(255, 0, 0, 0.2);
    border-radius: 15px;
    padding: 2rem;
    position: relative;
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.card-prism {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(135deg, transparent 48%, rgba(255,0,0,0.1) 49%, rgba(255,0,0,0.1) 51%, transparent 52%),
        linear-gradient(45deg, transparent 48%, rgba(139,0,0,0.1) 49%, rgba(139,0,0,0.1) 51%, transparent 52%);
    background-size: 30px 30px;
    animation: lightningPulse 2s ease-in-out infinite;
    pointer-events: none;
}

@keyframes lightningPulse {
    0%, 100% { opacity: 0.3; }
    50% { opacity: 0.7; }
}

@keyframes rotate {
    100% {
        transform: rotate(360deg);
    }
}

.card-content {
    position: relative;
    z-index: 1;
}

.service-card h3 {
    color: #ff4444;
    margin-bottom: 0.5rem;
    font-size: 1.5rem;
}

.service-name {
    font-size: 1.2rem;
    color: #ff6666;
    margin-bottom: 1rem;
    font-weight: bold;
}

.service-card p {
    color: #cccccc;
    line-height: 1.6;
    margin-bottom: 1.5rem;
}

.service-link {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    color: #ff4444;
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s, transform 0.3s;
}

.service-link:hover {
    color: #ff6666;
    transform: translateX(5px);
}

.arrow {
    transition: transform 0.3s;
}

.service-link:hover .arrow {
    transform: translateX(5px);
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(255,0,0,0.2);
    border-color: rgba(255,0,0,0.4);
}

/* 事業内容セクション */
.business-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-bottom: 3rem;
}

.business-card {
    background: rgba(20, 0, 0, 0.8);
    border-left: 4px solid #ff0000;
    padding: 2rem;
    transition: transform 0.3s, box-shadow 0.3s;
}

.card-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.prism-icon {
    width: 40px;
    height: 40px;
    position: relative;
    overflow: hidden;
}

.prism-icon::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 3px;
    height: 100%;
    background: linear-gradient(to bottom, transparent, #ff0000, #8b0000, #ff0000, transparent);
    transform: translate(-50%, -50%) rotate(-15deg);
    animation: lightningStrike 3s ease-in-out infinite;
}

.prism-icon::after {
    content: '';
    position: absolute;
    top: 30%;
    left: 20%;
    width: 2px;
    height: 40%;
    background: #ff6666;
    transform: rotate(25deg);
    animation: lightningStrike 3s ease-in-out infinite 0.5s;
}

@keyframes lightningStrike {
    0%, 90%, 100% { opacity: 0; }
    91%, 93%, 95%, 97% { opacity: 1; }
    92%, 94%, 96% { opacity: 0.3; }
}

.business-card h3 {
    color: #ff4444;
    font-size: 1.3rem;
}

.business-card p {
    color: #cccccc;
    line-height: 1.6;
}

.business-card:hover {
    transform: translateX(10px);
    box-shadow: -5px 0 20px rgba(255,0,0,0.2);
}

.company-info {
    background: rgba(20, 0, 0, 0.6);
    border: 1px solid rgba(255, 0, 0, 0.2);
    border-radius: 10px;
    padding: 2rem;
    margin-top: 3rem;
}

.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.info-item {
    text-align: center;
}

.info-label {
    display: block;
    color: #ff6666;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.info-value {
    display: block;
    color: #ffffff;
    font-size: 1.2rem;
    font-weight: bold;
}

/* メッセージセクション */
.message-section {
    padding: 4rem 0;
    background: linear-gradient(180deg, rgba(0,0,0,0.95), rgba(20,0,0,0.98), rgba(0,0,0,0.95));
    position: relative;
    overflow: hidden;
}

.message-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 100%;
    background: 
        repeating-linear-gradient(
            90deg,
            transparent,
            transparent 100px,
            rgba(255, 0, 0, 0.03) 100px,
            rgba(255, 0, 0, 0.03) 200px
        );
    pointer-events: none;
}

.message-box {
    background: rgba(10, 0, 0, 0.8);
    border: 2px solid rgba(255, 0, 0, 0.3);
    border-radius: 20px;
    padding: 3rem;
    box-shadow: 
        0 0 30px rgba(255, 0, 0, 0.2),
        inset 0 0 30px rgba(255, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
    animation: messageGlow 3s ease-in-out infinite;
}

@keyframes messageGlow {
    0%, 100% { box-shadow: 0 0 30px rgba(255, 0, 0, 0.2), inset 0 0 30px rgba(255, 0, 0, 0.05); }
    50% { box-shadow: 0 0 50px rgba(255, 0, 0, 0.3), inset 0 0 50px rgba(255, 0, 0, 0.1); }
}

.message-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, transparent, rgba(255, 0, 0, 0.8), transparent);
    animation: messageScan 3s linear infinite;
}

@keyframes messageScan {
    0% { left: -100%; }
    100% { left: 100%; }
}

.message-title {
    color: #ff6666;
    font-size: 2rem;
    margin-bottom: 1.5rem;
    text-align: center;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 3px;
    text-shadow: 
        0 0 10px rgba(255, 0, 0, 0.5),
        0 0 20px rgba(255, 0, 0, 0.3);
}

.message-title::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #ff0000, transparent);
    animation: pulse 2s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.3; width: 100px; }
    50% { opacity: 1; width: 150px; }
}

.message-content-area {
    padding: 2rem;
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 0, 0, 0.2);
    border-radius: 15px;
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
}

.message-content-area::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 0, 0, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 50%, rgba(255, 0, 0, 0.05) 0%, transparent 50%);
    pointer-events: none;
}

.dynamic-message {
    color: #cccccc;
    font-size: 1.1rem;
    line-height: 1.8;
    text-align: center;
    margin: 0;
    position: relative;
    z-index: 1;
}

.dynamic-message.has-content {
    color: #ffffff;
    font-size: 1.3rem;
    font-weight: 500;
    text-shadow: 0 0 5px rgba(255, 255, 255, 0.3);
    animation: messageFlicker 5s ease-in-out infinite;
}

@keyframes messageFlicker {
    0%, 100% { opacity: 1; }
    95% { opacity: 1; }
    96% { opacity: 0.9; }
    97% { opacity: 1; }
}

@media (max-width: 768px) {
    .message-section {
        padding: 3rem 0;
    }
    
    .message-box {
        padding: 2rem 1.5rem;
    }
    
    .message-title {
        font-size: 1.5rem;
    }
    
    .message-content-area {
        padding: 1.5rem;
        min-height: 100px;
    }
    
    .dynamic-message {
        font-size: 1rem;
    }
}

/* お問い合わせセクション */
.contact-section {
    background: linear-gradient(180deg, rgba(0,0,0,0.8), rgba(20,0,0,0.9), rgba(0,0,0,0.8));
    border-top: 2px solid rgba(255, 0, 0, 0.3);
    border-bottom: 2px solid rgba(255, 0, 0, 0.3);
}

.contact-form {
    max-width: 600px;
    margin: 0 auto;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.form-group {
    position: relative;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(0, 0, 0, 0.9);
    border: 2px solid rgba(255, 0, 0, 0.3);
    border-radius: 8px;
    color: #ffffff;
    font-size: 1rem;
    transition: all 0.3s;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #ff6666;
    opacity: 0.5;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #ff0000;
    box-shadow: 0 0 20px rgba(255,0,0,0.4), inset 0 0 10px rgba(255,0,0,0.1);
    background: rgba(20, 0, 0, 0.9);
}

.input-glow {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 8px;
    opacity: 0;
    background: radial-gradient(ellipse at center, rgba(255,0,0,0.3), transparent 70%);
    pointer-events: none;
    transition: opacity 0.3s;
}

.form-group input:focus ~ .input-glow,
.form-group textarea:focus ~ .input-glow {
    opacity: 1;
}

.submit-btn {
    width: 100%;
    padding: 1rem 2rem;
    background: linear-gradient(135deg, #ff0000, #8b0000);
    color: #ffffff;
    border: 2px solid #ff0000;
    border-radius: 8px;
    font-size: 1.2rem;
    font-weight: bold;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.btn-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255,255,255,0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.submit-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(255,0,0,0.5);
    background: linear-gradient(135deg, #ff3333, #cc0000);
    border-color: #ff3333;
}

.submit-btn:hover .btn-glow {
    width: 300px;
    height: 300px;
}

.submit-btn:active {
    transform: translateY(-1px);
    box-shadow: 0 5px 20px rgba(255,0,0,0.4);
}

/* フッター */
.main-footer {
    background: rgba(0, 0, 0, 0.95);
    border-top: 1px solid rgba(255, 0, 0, 0.2);
    padding: 2rem;
    text-align: center;
}

.footer-content p {
    color: #666666;
}

/* レスポンシブデザイン */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .section-title {
        font-size: 2rem;
    }
    
    .nav-menu {
        gap: 1rem;
        font-size: 0.9rem;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .services-grid,
    .business-grid {
        grid-template-columns: 1fr;
    }
    
    .logo {
        height: 40px;
        max-width: 150px;
    }
}