@import url('fonts.css');

.ifrog-hero{
    --green:#8fe441; --green-2:#7fd634; --ink:#fff; --muted:#cfe0d4;
    --bg:#0f1a13; --shell:1280px;
    position:relative; z-index:2000; box-sizing:border-box;
    min-height:100vh; min-height:100dvh;
    display:flex; flex-direction:column;
    overflow:hidden; isolation:isolate;
    color:var(--ink); background:var(--bg) url("../assets/home_bg.jpg") center/cover no-repeat;
    font-family:"Manrope",-apple-system,"Segoe UI",Roboto,Arial,sans-serif;
    -webkit-font-smoothing:antialiased;
}
.ifrog-hero *,.ifrog-hero *::before,.ifrog-hero *::after{box-sizing:border-box}
.ifrog-hero a{text-decoration:none;color:inherit}

/* ---- фон: видео + затемнение (защита от белого экрана) ---- */
.ifrog-hero__video{
    position:absolute; inset:0; width:100%; height:100%;
    object-fit:cover; z-index:-2; border:0; background:var(--bg);
    animation:ifrog-kenburns 22s ease-in-out infinite alternate;
}
@keyframes ifrog-kenburns{from{transform:scale(1.04)}to{transform:scale(1.12)}}
.ifrog-hero__scrim{
    position:absolute; inset:0; z-index:-1; pointer-events:none;
    background:
            linear-gradient(90deg, rgba(7,13,10,.86) 0%, rgba(7,13,10,.55) 46%, rgba(7,13,10,.22) 100%),
            linear-gradient(0deg, rgba(7,13,10,.65) 0%, rgba(7,13,10,0) 42%);
}

/* ---------------------- шапка ---------------------- */
.ifrog-hero__header{
    position:fixed; top:0; left:0; right:0; z-index:20;
    display:flex; align-items:center; justify-content:space-between;
    padding:clamp(18px,3vw,30px) clamp(20px,5vw,72px);
    background:transparent; -webkit-backdrop-filter:blur(0); backdrop-filter:blur(0);
    transition:background-color .35s ease, backdrop-filter .35s ease,
    -webkit-backdrop-filter .35s ease, padding .35s ease;
}
.ifrog-hero__header.is-scrolled{
    background:rgba(9,15,12,.72);
    -webkit-backdrop-filter:blur(12px); backdrop-filter:blur(12px);
    padding-top:clamp(12px,2vw,18px); padding-bottom:clamp(12px,2vw,18px);
}
.ifrog-hero__logo{flex-shrink:0;display:flex}
.ifrog-hero__logo svg{display:block;height:30px;width:auto}
.ifrog-hero__logo-frog{fill:#fff;transition:fill .2s ease} /* «Frog» — белый, зеленеет на hover */
.ifrog-hero__logo:hover .ifrog-hero__logo-frog{fill:var(--green)}
.ifrog-hero__nav{
    position:absolute; left:50%; top:50%; transform:translate(-50%,-50%);
    display:flex; gap:clamp(20px,3vw,40px); align-items:center;
}
.ifrog-hero__nav a{font-size:15px;color:var(--muted);transition:color .2s}
.ifrog-hero__nav a:hover{color:var(--ink)}
.ifrog-hero__nav .ifrog-hero__phone{display:none} /* дублирующий телефон в меню — только для мобильного оверлея */
.ifrog-hero__phone{font-size:18px;font-weight:700;letter-spacing:.3px;white-space:nowrap}
.ifrog-hero__burger{
    display:none; flex-direction:column; gap:5px; cursor:pointer;
    padding:8px; background:none; border:0; z-index:30;
}
.ifrog-hero__burger span{width:26px;height:2px;background:var(--ink);border-radius:2px;transition:.25s}

/* ---------------------- контент ---------------------- */
.ifrog-hero__main{
    flex:1; display:flex; align-items:center;
    padding:120px clamp(20px,5vw,72px) 150px;
}
.ifrog-hero__inner{width:100%;max-width:var(--shell);margin:0 auto}
.ifrog-hero__content{width:100%}
.ifrog-hero__eyebrow{
    display:block; font-weight:700; font-size:clamp(18px,2.4vw,24px);
    color:var(--ink); margin:0 0 6px;
}
.ifrog-hero__eyebrow i{font-style:normal;color:var(--green)}
.ifrog-hero__title{margin:0}
.ifrog-hero__title strong{
    display:block; white-space:nowrap; text-transform:uppercase;
    font-family:"Rubik",system-ui,sans-serif; font-weight:800;
    letter-spacing:-.022em; line-height:1.02;
    font-size:64px; /* стартовое; уточняется скриптом под ширину */
}
.ifrog-hero__title strong.is-typing::after{
    content:""; display:inline-block; width:.05em; height:.82em; margin-left:.12em;
    background:var(--green); vertical-align:baseline;
    animation:ifrog-caret .7s steps(1,end) infinite;
}
@keyframes ifrog-caret{50%{opacity:0}}
.ifrog-hero__subtitle{
    margin:clamp(18px,2.4vw,28px) 0 0;
    font-size:clamp(16px,2.1vw,20px); line-height:1.5; font-weight:400; color:#eef4f0;
}
.ifrog-hero__subtitle b{color:var(--green);font-weight:500}
.ifrog-hero__cta{
    margin-top:clamp(24px,3.4vw,40px);
    display:inline-flex; align-items:center; gap:10px;
    padding:16px 34px; border:0; border-radius:12px; cursor:pointer;
    font-family:"Manrope",sans-serif; font-weight:700; font-size:16px;
    color:#0b3d10; background:var(--green);
    transition:transform .18s, background .2s, box-shadow .2s;
    box-shadow:0 12px 34px rgba(143,228,65,.28);
}
.ifrog-hero__cta:hover{background:var(--green-2);transform:translateY(-2px);box-shadow:0 16px 42px rgba(143,228,65,.36)}

/* ---------------------- Фредди снизу ---------------------- */
.ifrog-hero__frog{
    position:absolute; right:clamp(0px,4vw,60px); bottom:0; z-index:2;
    width:min(300px,32vw); pointer-events:none;
    filter:drop-shadow(0 20px 26px rgba(0,0,0,.5));
}
.ifrog-hero__frog img{display:block;width:100%;height:auto}

/* ---------------------- адаптив ---------------------- */
@media (max-width:900px){
    .ifrog-hero__nav,.ifrog-hero__phone{display:none}
    .ifrog-hero__burger{display:flex}
    .ifrog-hero__main{padding:110px clamp(18px,6vw,32px) 140px}
    .ifrog-hero__frog{width:min(210px,44vw);right:0}
    /* мобильное меню */
    .ifrog-hero__nav.is-open{
        display:flex; position:fixed; inset:0; transform:none; z-index:25;
        flex-direction:column; justify-content:center; align-items:center; gap:26px;
        background:rgba(9,15,12,.97); -webkit-backdrop-filter:blur(6px); backdrop-filter:blur(6px);
    }
    .ifrog-hero__nav.is-open a{font-size:22px;color:var(--ink)}
    .ifrog-hero__nav.is-open .ifrog-hero__phone{display:block;color:var(--green)}
    .ifrog-hero__burger.is-open span:nth-child(1){transform:translateY(7px) rotate(45deg)}
    .ifrog-hero__burger.is-open span:nth-child(2){opacity:0}
    .ifrog-hero__burger.is-open span:nth-child(3){transform:translateY(-7px) rotate(-45deg)}
}
@media (max-width:480px){
    .ifrog-hero__frog{width:150px;opacity:.9}
    .ifrog-hero__subtitle{max-width:100%}
}
@media (prefers-reduced-motion:reduce){
    .ifrog-hero__video{animation:none}
}
