/* ═══════════════════════════════════════════
   MindMatch Homepage Widget — v1.0.0
   ═══════════════════════════════════════════ */

/* ── Widget shell ── */
.mmh-widget {
        position: relative;
        overflow: hidden;
        background: linear-gradient(145deg, #e8f8f8 0%, #d0f0f1 50%, #c0e8ea 100%);
        border-radius: 24px;
        font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
        opacity: 0;
        transform: translateY(20px);
        animation: mmh-enter 0.6s cubic-bezier(.4,0,.2,1) 0.1s forwards;
}

/* Portrait: stacked, centred, narrow */
.mmh-widget--portrait {
        max-width: 340px;
        margin: 0 auto;
        padding: 0.85rem 1.5rem 1.5rem;
        text-align: center;
}

/* Landscape: side-by-side, wide */
.mmh-widget--landscape {
        max-width: 680px;
        margin: 0 auto;
        padding: 2rem 2.5rem;
        display: flex;
        align-items: center;
        gap: 2.5rem;
        text-align: left;
}

@keyframes mmh-enter {
        to { opacity: 1; transform: translateY(0); }
}

/* ── Orbs ── */
.mmh-orb {
        position: absolute;
        border-radius: 50%;
        pointer-events: none;
        opacity: 0.4;
}
.mmh-orb--1 {
        width: 160px; height: 160px;
        background: radial-gradient(circle, #2bb5ba55, transparent 70%);
        top: -50px; right: -50px;
        animation: mmh-float1 7s ease-in-out infinite;
}
.mmh-orb--2 {
        width: 100px; height: 100px;
        background: radial-gradient(circle, #1a444430, transparent 70%);
        bottom: -25px; left: -25px;
        animation: mmh-float2 9s ease-in-out infinite 1.5s;
}
@keyframes mmh-float1 {
        0%, 100% { transform: translate(0,0) scale(1); }
        50%       { transform: translate(-14px,18px) scale(1.1); }
}
@keyframes mmh-float2 {
        0%, 100% { transform: translate(0,0) scale(1); }
        50%       { transform: translate(16px,-12px) scale(0.9); }
}

/* ── Logo ── */
.mmh-logo-wrap {
        flex-shrink: 0;
        margin-bottom: 0.4rem;
}
.mmh-widget--landscape .mmh-logo-wrap {
        margin-bottom: 0;
}
.mmh-logo {
        width: 180px;
        height: auto;
        display: block;
        margin: 0 auto;
}
.mmh-widget--landscape .mmh-logo {
        width: 130px;
        height: auto;
}

/* ── Content ── */
.mmh-content { flex: 1; }

.mmh-title {
        font-size: 1.35rem !important;
        font-weight: 900 !important;
        color: #1a4444 !important;
        margin: 0 0 0.5rem !important;
        padding: 0 !important;
        border: none !important;
        line-height: 1.2 !important;
}

.mmh-subtitle {
        font-size: 0.88rem;
        color: #3a6060;
        margin: 0 0 1.25rem;
        line-height: 1.5;
}

/* ── Cycling tool label ── */
.mmh-tool-label {
        display: inline-flex;
        align-items: center;
        gap: 8px;
        font-size: 0.9rem;
        color: #3a6060;
        margin: 0 0 1.25rem;
        font-weight: 500;
}

.mmh-tick {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 20px;
        height: 20px;
        min-width: 20px;
        background: #2bb5ba;
        border-radius: 50%;
        flex-shrink: 0;
}
.mmh-tick::after {
        content: '';
        display: block;
        width: 5px;
        height: 9px;
        border: 2px solid #fff;
        border-top: none;
        border-left: none;
        transform: rotate(45deg) translate(-1px, -1px);
}

.mmh-tool-word {
        display: inline-block;
        font-weight: 700;
        color: #1a4444;
        min-width: 120px;
        transition: opacity 0.3s, transform 0.3s;
}
.mmh-tool-word.mmh-fade-out {
        opacity: 0;
        transform: translateY(-6px);
}
.mmh-tool-word.mmh-fade-in {
        opacity: 0;
        transform: translateY(6px);
}

/* ── Button ── */
@keyframes mmh-pulse {
        0%   { box-shadow: 0 0 0 0 rgba(43,181,186,0.55); }
        70%  { box-shadow: 0 0 0 12px rgba(43,181,186,0); }
        100% { box-shadow: 0 0 0 0 rgba(43,181,186,0); }
}

.mmh-btn {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        gap: 0.5rem;
        width: 100%;
        padding: 0.9rem 1.5rem;
        background: #2bb5ba;
        color: #fff !important;
        font-size: 1rem;
        font-weight: 700;
        border-radius: 50px;
        text-decoration: none !important;
        position: relative;
        overflow: hidden;
        transition: background 0.22s, transform 0.18s;
        box-shadow: 0 4px 18px rgba(43,181,186,0.35);
        animation: mmh-pulse 2s ease-out infinite;
        margin-bottom: 0.75rem;
}
.mmh-btn:hover {
        background: #1a9fa4;
        transform: translateY(-2px);
        animation: none;
        box-shadow: 0 8px 28px rgba(43,181,186,0.5);
}
.mmh-btn:active { transform: translateY(0); }

.mmh-btn__arrow {
        width: 18px;
        height: 18px;
        flex-shrink: 0;
        transition: transform 0.2s;
}
.mmh-btn:hover .mmh-btn__arrow { transform: translateX(4px); }

.mmh-widget--landscape .mmh-tool-label {
        display: flex;
        margin-bottom: 1rem;
}
.mmh-widget--landscape .mmh-btn {
        width: auto;
        padding: 0.85rem 2rem;
        margin-top: 0.25rem;
}

/* Ripple */
.mmh-ripple {
        position: absolute;
        border-radius: 50%;
        background: rgba(255,255,255,0.35);
        transform: scale(0);
        animation: mmh-ripple-anim 0.55s linear;
        pointer-events: none;
}
@keyframes mmh-ripple-anim {
        to { transform: scale(4); opacity: 0; }
}

/* ── Meta ── */
.mmh-meta {
        font-size: 0.75rem;
        color: #6a9898;
        margin: 0;
        line-height: 1.4;
}

/* ── Landscape: collapse to portrait on small screens ── */
@media (max-width: 560px) {
        .mmh-widget--landscape {
                flex-direction: column;
                text-align: center;
                max-width: 340px;
                padding: 2rem 1.5rem 1.75rem;
        }
        .mmh-widget--landscape .mmh-logo-wrap {
                margin-bottom: 1.25rem;
        }
        .mmh-widget--landscape .mmh-btn {
                width: 100%;
        }
        .mmh-widget--landscape .mmh-tools {
                text-align: left;
        }
}
