/**
 * メルマガ登録CTAセクション スタイル
 *
 * @package Corporate_SEO_Pro
 */

/* ==========================================================================
   メルマガCTAセクション
   ========================================================================== */

.newsletter-cta {
    position: relative;
    padding: 4rem 0;
    overflow: hidden;
    width: 100vw !important;
    max-width: 100vw !important;
    margin-left: calc(-50vw + 50%) !important;
    box-sizing: border-box;
}

/* 背景 */
.newsletter-cta-background {
    position: absolute;
    inset: 0;
    z-index: 0;
}

.newsletter-cta-gradient {
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #00867b 0%, #10b981 50%, #00867b 100%);
    background-size: 200% 200%;
    animation: gradientShift 15s ease infinite;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

.newsletter-cta-pattern {
    position: absolute;
    inset: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.5;
}

.newsletter-cta-glow {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.15) 0%, transparent 70%);
    pointer-events: none;
}

/* コンテナ上書き */
.newsletter-cta .container {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0 1rem;
}

/* コンテンツ */
.newsletter-cta-content {
    position: relative;
    z-index: 1;
    text-align: center;
    color: white;
    width: 100%;
    max-width: 700px;
    margin-left: auto !important;
    margin-right: auto !important;
    padding: 0 1rem;
    box-sizing: border-box;
}

/* アイコン */
.newsletter-cta-icon {
    width: 80px;
    height: 80px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    animation: iconFloat 3s ease-in-out infinite;
}

@keyframes iconFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.newsletter-cta-icon i {
    font-size: 2rem;
    color: white;
}

/* タイトル */
.newsletter-cta-title {
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.4;
    color: white;
}

/* 説明文 */
.newsletter-cta-description {
    font-size: 1rem;
    line-height: 1.7;
    margin-bottom: 2rem;
    opacity: 0.95;
    color: rgba(255, 255, 255, 0.95);
}

/* フォーム */
.newsletter-form {
    margin-bottom: 1rem;
    width: 100%;
}

.newsletter-form-group {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
    max-width: 500px;
    margin-left: auto !important;
    margin-right: auto !important;
    box-sizing: border-box;
}

.newsletter-form-group input[type="email"] {
    display: block;
    width: 100% !important;
    min-width: 100%;
    max-width: 100%;
    box-sizing: border-box;
    padding: 1.1rem 1.5rem;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    background: white;
    color: #1f2937;
    outline: none;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.newsletter-form-group input[type="email"]::placeholder {
    color: #9ca3af;
}

.newsletter-form-group input[type="email"]:focus {
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.3), 0 4px 15px rgba(0, 0, 0, 0.1);
}

/* 送信ボタン */
.newsletter-submit-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 1.1rem 2rem;
    background: #1f2937;
    color: white;
    border: none;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    white-space: nowrap;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
}

.newsletter-submit-btn:hover {
    background: #374151;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.newsletter-submit-btn:active {
    transform: translateY(0);
}

.newsletter-submit-btn .btn-loading {
    display: none;
}

.newsletter-submit-btn.is-loading .btn-text,
.newsletter-submit-btn.is-loading .btn-icon {
    display: none;
}

.newsletter-submit-btn.is-loading .btn-loading {
    display: inline-block;
}

.newsletter-submit-btn:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

/* メッセージ */
.newsletter-form-message {
    min-height: 1.5rem;
    margin-top: 1rem;
    font-size: 0.9rem;
    font-weight: 500;
}

.newsletter-form-message.success {
    color: #d1fae5;
}

.newsletter-form-message.error {
    color: #fecaca;
}

/* プライバシー */
.newsletter-privacy {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
}

.newsletter-privacy i {
    font-size: 0.75rem;
}

/* パーティクル */
.newsletter-particles {
    position: absolute;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
}

.newsletter-particle {
    position: absolute;
    width: 8px;
    height: 8px;
    background: rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    animation: particleFloat 10s ease-in-out infinite;
}

.newsletter-particle:nth-child(1) {
    top: 20%;
    left: 10%;
    animation-delay: 0s;
}

.newsletter-particle:nth-child(2) {
    top: 60%;
    left: 20%;
    animation-delay: 2s;
    width: 6px;
    height: 6px;
}

.newsletter-particle:nth-child(3) {
    top: 30%;
    right: 15%;
    animation-delay: 4s;
}

.newsletter-particle:nth-child(4) {
    top: 70%;
    right: 25%;
    animation-delay: 6s;
    width: 10px;
    height: 10px;
}

.newsletter-particle:nth-child(5) {
    top: 50%;
    left: 5%;
    animation-delay: 8s;
    width: 5px;
    height: 5px;
}

@keyframes particleFloat {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
        opacity: 0.3;
    }
    50% {
        transform: translateY(-20px) rotate(180deg);
        opacity: 0.6;
    }
}

/* SP用改行 */
.sp-only {
    display: none;
}

/* ==========================================================================
   レスポンシブ
   ========================================================================== */

@media (max-width: 768px) {
    .newsletter-cta {
        padding: 3rem 1rem;
        width: 100vw !important;
        margin-left: calc(-50vw + 50%) !important;
    }

    .newsletter-cta .container {
        padding: 0 1rem;
    }

    .newsletter-cta-content {
        max-width: 100%;
        padding: 0 0.5rem;
    }

    .newsletter-cta-icon {
        width: 64px;
        height: 64px;
    }

    .newsletter-cta-icon i {
        font-size: 1.5rem;
    }

    .newsletter-cta-title {
        font-size: 1.35rem;
    }

    .newsletter-cta-description {
        font-size: 0.9rem;
    }

    .newsletter-form-group {
        max-width: 100% !important;
        width: 100% !important;
        gap: 0.75rem;
        padding: 0;
    }

    .newsletter-form-group input[type="email"] {
        padding: 1rem 1.25rem;
        width: 100% !important;
    }

    .newsletter-submit-btn {
        padding: 1rem;
    }

    .sp-only {
        display: inline;
    }

    .newsletter-particles {
        display: none;
    }
}

@media (max-width: 480px) {
    .newsletter-cta {
        padding: 2.5rem 0.75rem;
    }

    .newsletter-cta .container {
        padding: 0 0.75rem;
    }

    .newsletter-cta-content {
        padding: 0;
    }

    .newsletter-cta-title {
        font-size: 1.2rem;
    }

    .newsletter-cta-description {
        font-size: 0.85rem;
        margin-bottom: 1.5rem;
    }

    .newsletter-form-group {
        padding: 0;
    }
}
