/* Riku Ichikawa product page: font, keyframes and effects. Layout lives in Tailwind classes in the templates. */

@font-face {
    font-family: 'Riku Satoshi';
    src: url('../fonts/Satoshi-Variable.ttf') format('truetype');
    font-weight: 300 900;
    font-display: swap;
}

/* Full-width sections (same overrides as the other Satoshi product pages) */
.columns {
    padding-left: 0 !important;
    padding-right: 0 !important;
    max-width: 3840px !important;
    width: 100% !important;
    row-gap: 0 !important;
}
.page-main {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}
.message.success { z-index: 999; }

.rk-page, .rk-end { font-family: 'Riku Satoshi', 'Satoshi', satoshi, sans-serif; }

/* ---------- Scroll reveal ---------- */
:where(.rk-js) [data-rk-reveal] {
    opacity: 0;
    transform: translate3d(0, 28px, 0);
    transition: opacity .8s cubic-bezier(.2, .7, .2, 1), transform .8s cubic-bezier(.2, .7, .2, 1);
    transition-delay: var(--rk-d, 0ms);
}
:where(.rk-js) [data-rk-reveal="left"]  { transform: translate3d(-36px, 0, 0); }
:where(.rk-js) [data-rk-reveal="right"] { transform: translate3d(36px, 0, 0); }
:where(.rk-js) [data-rk-reveal="pop"]   { transform: scale(.82) rotate(-6deg); }
:where(.rk-js) [data-rk-reveal="zoom"]  { transform: scale(.9); }
:where(.rk-js) [data-rk-reveal].is-in   { opacity: 1; transform: none; }

/* ---------- Hero ---------- */
.rk-hero-bg {
    animation: rk-kenburns 26s ease-in-out infinite alternate;
    transform-origin: 70% 40%;
}
@keyframes rk-kenburns {
    from { transform: scale(1); }
    to   { transform: scale(1.09) translate3d(-1.5%, 1%, 0); }
}

.rk-word {
    display: inline-block;
    opacity: 0;
    transform: translate3d(0, .6em, 0) rotate(4deg);
    animation: rk-word-in .7s cubic-bezier(.2, .8, .2, 1.15) forwards;
    animation-delay: calc(var(--i, 0) * 55ms + 150ms);
}
@keyframes rk-word-in { to { opacity: 1; transform: none; } }

.rk-mark {
    position: relative;
    white-space: nowrap;
    background: linear-gradient(90deg, #fff 0%, #fff 40%, #ffd6e8 50%, #fff 60%, #fff 100%);
    background-size: 250% 100%;
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rk-shimmer 4.5s ease-in-out 1.6s infinite;
}
.rk-mark::after {
    content: '';
    position: absolute;
    left: 0; right: 0; bottom: -.04em;
    height: .14em;
    border-radius: 99px;
    background: #F6C3D9;
    transform: scaleX(0);
    transform-origin: left;
    animation: rk-underline .9s cubic-bezier(.6, 0, .2, 1) 1.1s forwards;
}
@keyframes rk-shimmer { 0%, 55% { background-position: 100% 0; } 100% { background-position: -50% 0; } }
@keyframes rk-underline { to { transform: scaleX(1); } }

.rk-fade-up {
    opacity: 0;
    transform: translate3d(0, 18px, 0);
    animation: rk-word-in .8s cubic-bezier(.2, .8, .2, 1) forwards;
    animation-delay: var(--rk-d, 0ms);
}

.rk-box-in {
    opacity: 0;
    animation: rk-box-in 1.1s cubic-bezier(.2, .8, .2, 1) .35s forwards;
}
@keyframes rk-box-in {
    from { opacity: 0; transform: translate3d(60px, 30px, 0) rotate(7deg); }
    to   { opacity: 1; transform: none; }
}
.rk-torso-in {
    opacity: 0;
    animation: rk-torso-in 1s cubic-bezier(.2, .9, .25, 1.2) .7s forwards;
}
@keyframes rk-torso-in {
    from { opacity: 0; transform: translate3d(-30px, -40px, 0) rotate(-10deg) scale(.9); }
    to   { opacity: 1; transform: none; }
}
.rk-float { animation: rk-float 5.5s ease-in-out 1.8s infinite; }
@keyframes rk-float {
    0%, 100% { transform: translate3d(0, 0, 0) rotate(0deg); }
    50%      { transform: translate3d(0, -14px, 0) rotate(-2deg); }
}

/* Sparkles */
.rk-spark {
    position: absolute;
    width: var(--s, 18px);
    height: var(--s, 18px);
    color: #fff;
    opacity: 0;
    animation: rk-twinkle 2.8s ease-in-out infinite;
    animation-delay: var(--rk-d, 0s);
    pointer-events: none;
}
@keyframes rk-twinkle {
    0%, 100% { opacity: 0; transform: scale(.4) rotate(0deg); }
    50%      { opacity: 1; transform: scale(1) rotate(90deg); }
}

/* Falling sakura petals */
.rk-petals { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.rk-petal {
    position: absolute;
    top: -6%;
    left: var(--x, 50%);
    width: var(--w, 14px);
    height: calc(var(--w, 14px) * .8);
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 16'%3E%3Cpath d='M10 15.5C4 13 .5 8.5 1.5 4.5 2.5.8 6.5.2 8.8 2.6L10 4l1.2-1.4C13.5.2 17.5.8 18.5 4.5c1 4-2.5 8.5-8.5 11z' fill='%23fff' fill-opacity='.92'/%3E%3Cpath d='M10 15.5C6 12 5 8 6.5 5' stroke='%23F6C3D9' stroke-width='.8' fill='none'/%3E%3C/svg%3E") center/contain no-repeat;
    opacity: .85;
    animation: rk-fall var(--t, 12s) linear var(--rk-d, 0s) infinite;
    will-change: transform;
}
@keyframes rk-fall {
    0%   { transform: translate3d(0, 0, 0) rotate(0deg) rotateX(0deg); }
    25%  { transform: translate3d(calc(var(--dx, 60px) * .5), 28vh, 0) rotate(120deg) rotateX(60deg); }
    50%  { transform: translate3d(calc(var(--dx, 60px) * -.2), 56vh, 0) rotate(220deg) rotateX(0deg); }
    75%  { transform: translate3d(calc(var(--dx, 60px) * .8), 84vh, 0) rotate(320deg) rotateX(60deg); }
    100% { transform: translate3d(var(--dx, 60px), 112vh, 0) rotate(420deg) rotateX(0deg); }
}

/* ---------- Buttons ---------- */
.rk-btn {
    position: relative;
    overflow: hidden;
    isolation: isolate;
    transition: transform .25s cubic-bezier(.2, .8, .2, 1.4), box-shadow .25s ease, background-color .2s ease;
}
.rk-btn::before {
    content: '';
    position: absolute;
    top: 0; bottom: 0; left: -60%;
    width: 45%;
    z-index: -1;
    background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .38), transparent);
    transform: skewX(-20deg);
    animation: rk-sheen 3.6s ease-in-out 2s infinite;
}
@keyframes rk-sheen { 0%, 70% { left: -60%; } 100% { left: 130%; } }
.rk-btn:hover { transform: translate3d(0, -2px, 0) scale(1.03); }
.rk-btn:active { transform: scale(.98); }
.rk-btn .rk-spin { display: none; width: 1.1em; height: 1.1em; animation: rk-rotate .8s linear infinite; }
.rk-btn[aria-busy="true"] { pointer-events: none; opacity: .85; }
.rk-btn[aria-busy="true"] .rk-spin { display: inline-block; }
@keyframes rk-rotate { to { transform: rotate(360deg); } }

.rk-nudge { animation: rk-nudge 1.6s ease-in-out infinite; }
@keyframes rk-nudge { 0%, 100% { transform: translateX(0); } 50% { transform: translateX(5px); } }

/* ---------- Why you'll love her ---------- */
.rk-chibi { transform-origin: 50% 100%; animation: rk-bob 3.2s ease-in-out infinite; animation-delay: var(--rk-d, 0s); }
@keyframes rk-bob {
    0%, 100% { transform: translate3d(0, 0, 0) rotate(-2deg); }
    50%      { transform: translate3d(0, -6px, 0) rotate(2deg); }
}
.rk-love-card:hover .rk-chibi { animation: rk-wiggle .5s ease-in-out 2; }
@keyframes rk-wiggle {
    0%, 100% { transform: rotate(0deg) scale(1.06); }
    25%      { transform: rotate(-8deg) scale(1.1); }
    75%      { transform: rotate(8deg) scale(1.1); }
}

.rk-marquee-track { animation: rk-marquee 38s linear infinite; }
.rk-marquee:hover .rk-marquee-track { animation-play-state: paused; }
@keyframes rk-marquee { to { transform: translate3d(-50%, 0, 0); } }

/* ---------- Story illustrations ---------- */
.rk-orbit {
    animation: rk-rotate 40s linear infinite;
}
.rk-bubble { animation: rk-float 4.6s ease-in-out infinite; }
.rk-bubble-in { animation-delay: .4s; }

.rk-quote-mark {
    font-family: Georgia, 'Times New Roman', serif;
    line-height: .6;
}

/* ---------- Tunnel map ---------- */
.rk-pin {
    transition: transform .25s cubic-bezier(.2, .8, .2, 1.5), background-color .2s ease, box-shadow .25s ease, opacity .2s ease;
}
.rk-pin::after {
    content: '';
    position: absolute;
    inset: -4px;
    border-radius: 99px;
    border: 2px solid #fff;
    opacity: 0;
}
:where(.rk-js) .rk-map.is-in .rk-pin::after {
    animation: rk-pin-ping 2.4s ease-out infinite;
    animation-delay: calc(var(--n, 1) * 180ms);
}
@keyframes rk-pin-ping {
    0%   { opacity: .9; transform: scale(.8); }
    60%, 100% { opacity: 0; transform: scale(2); }
}
.rk-map.has-active .rk-pin { opacity: .45; }
.rk-map.has-active .rk-pin.is-active {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.45);
    background: #C42962;
    box-shadow: 0 0 0 6px rgba(246, 195, 217, .55), 0 8px 24px rgba(130, 50, 80, .45);
}
.rk-stage { transition: background-color .2s ease, transform .2s ease; }
.rk-stage.is-active { background: #FBE3EE; transform: translateX(4px); }
.rk-stage.is-active .rk-stage-n { background: #823250; transform: scale(1.12); }
.rk-stage-n { transition: transform .2s ease, background-color .2s ease; }

/* ---------- Specs ---------- */
.rk-measure-label { transition: opacity .6s ease, transform .6s cubic-bezier(.2, .8, .2, 1.3); }
:where(.rk-js) .rk-measure:not(.is-in) .rk-measure-label { opacity: 0; transform: translate(-50%, -50%) scale(.6); }

/* ---------- Order box ---------- */
.rk-order {
    background: linear-gradient(110deg, #C42962 0%, #C42962 40%, #D9447B 50%, #C42962 60%, #C42962 100%);
    background-size: 300% 100%;
    animation: rk-order-glow 5s ease-in-out infinite;
}
@keyframes rk-order-glow { 0%, 100% { background-position: 100% 0; } 50% { background-position: 0 0; } }
.rk-order:hover { box-shadow: 0 18px 40px -12px rgba(196, 41, 98, .65); }

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
    .rk-page *, .rk-end * { animation: none !important; transition: none !important; }
    .rk-word, .rk-fade-up, .rk-box-in, .rk-torso-in { opacity: 1 !important; transform: none !important; }
    .rk-mark::after { transform: none; }
    .rk-petals, .rk-spark { display: none !important; }
    :where(.rk-js) [data-rk-reveal] { opacity: 1; transform: none; }
}
