/* Mobile contact keeps every path on the same page; desktop retains the water form. */
@media (max-width: 680px) {
  .ap-responsive-contact {
    background: var(--ap-paper, #f2f1ef) !important;
    color: var(--ap-ink, #171717);
  }
  [data-theme="dark"] .ap-responsive-contact {
    background: #101113 !important;
    color: #f4f3f1;
  }
  .ap-responsive-contact .ap-mobile-contact { display: block !important; }
  .ap-responsive-contact .ap-desktop-contact { display: block !important; }
  .ap-responsive-contact .ap-desktop-contact .landscape,
  .ap-responsive-contact .ap-desktop-contact #water,
  .ap-responsive-contact .ap-desktop-contact .ap-water-control { display: none !important; }
  .ap-responsive-contact .ap-mobile-contact .ap-contact-hub {
    padding: 132px 0 40px;
    background: transparent !important;
  }
  .ap-responsive-contact .ap-hub-heading { width: calc(100% - 40px); }
  .ap-responsive-contact .ap-hub-heading h1 {
    font-size: clamp(64px, 17vw, 92px);
    letter-spacing: -.075em;
    line-height: .98;
    margin: 24px 0 14px;
  }
  .ap-responsive-contact .ap-hub-heading > p:last-child {
    color: var(--ap-detail, #777);
    font-size: 17px;
    line-height: 1.55;
    margin: 0;
  }
  .ap-contact-quick {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    width: calc(100% - 40px);
    margin: 30px auto 0;
  }
  .ap-contact-quick a {
    min-height: 74px;
    padding: 14px 15px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 4px;
    border: 1px solid #8b8d9130;
    border-radius: 17px;
    background: #ffffffa8;
    color: inherit;
    text-decoration: none;
    box-shadow: 0 8px 24px #1111;
    -webkit-backdrop-filter: blur(18px) saturate(1.12);
    backdrop-filter: blur(18px) saturate(1.12);
  }
  [data-theme="dark"] .ap-contact-quick a {
    background: #242629bb;
    border-color: #ffffff1a;
    box-shadow: 0 9px 24px #0003;
  }
  .ap-contact-quick a:active { transform: scale(.985); }
  .ap-contact-quick a span { font-size: 14px; font-weight: 550; }
  .ap-contact-quick a small { color: var(--ap-detail, #777); font-size: 10px; line-height: 1.4; }
  .ap-responsive-contact .ap-bubble-universe {
    margin-top: 26px;
    padding: 0 20px 178px;
  }
  .ap-responsive-contact .ap-bubble-field { max-width: 390px; height: 780px; }
  .ap-responsive-contact .ap-channel-dock {
    z-index: 29;
    bottom: calc(92px + env(safe-area-inset-bottom));
    width: calc(100% - 32px);
    max-width: 390px;
    padding: 15px 18px;
    border: 1px solid #ffffff5c;
    border-radius: 19px;
    background: #f8f8f5e8;
    color: #171717;
    box-shadow: 0 12px 38px #0002;
    -webkit-backdrop-filter: blur(24px) saturate(1.15);
    backdrop-filter: blur(24px) saturate(1.15);
  }
  [data-theme="dark"] .ap-responsive-contact .ap-channel-dock {
    background: #202225ed;
    color: #f5f4f2;
    border-color: #ffffff1a;
    box-shadow: 0 12px 38px #0005;
  }
  .ap-responsive-contact .ap-hub-bottom { width: calc(100% - 40px); }
  .ap-responsive-contact .ap-desktop-contact .ap-contact-layout {
    display: block;
    width: calc(100% - 40px);
    max-width: 560px;
    padding: 8px 0 calc(118px + env(safe-area-inset-bottom));
  }
  .ap-responsive-contact .ap-desktop-contact .ap-contact-intro { display: none; }
  .ap-responsive-contact .ap-desktop-contact .ap-contact-card {
    width: 100%;
    padding: 25px 21px;
    border-radius: 21px;
    background: #ffffffd9;
    border: 1px solid #8b8d9126;
    box-shadow: 0 14px 45px #1112;
    -webkit-backdrop-filter: blur(22px) saturate(1.1);
    backdrop-filter: blur(22px) saturate(1.1);
  }
  [data-theme="dark"] .ap-responsive-contact .ap-desktop-contact .ap-contact-card {
    background: #1c1e20ed;
    border-color: #ffffff20;
    box-shadow: 0 14px 45px #0004;
  }
  .ap-responsive-contact .ap-desktop-contact .ap-contact-card h2 { font-size: 31px; }
  .ap-riko-launcher {
    position: fixed;
    z-index: 35;
    right: 17px;
    bottom: calc(16px + env(safe-area-inset-bottom));
    display: inline-flex;
    align-items: center;
    gap: 9px;
    min-height: 54px;
    padding: 6px 17px 6px 7px;
    border: 1px solid #ffffff82;
    border-radius: 999px;
    background: #f7f7f4e8;
    color: #161719;
    font-family: inherit;
    font-size: 13px;
    font-weight: 550;
    line-height: 1;
    box-shadow: 0 10px 30px #0003;
    -webkit-backdrop-filter: blur(22px) saturate(1.2);
    backdrop-filter: blur(22px) saturate(1.2);
    cursor: pointer;
  }
  [data-theme="dark"] .ap-riko-launcher {
    background: #292b2fee;
    color: #f7f6f4;
    border-color: #ffffff20;
    box-shadow: 0 10px 30px #0006;
  }
  .ap-riko-avatar {
    display: grid;
    place-items: center;
    width: 39px;
    height: 39px;
    border-radius: 50%;
    background: linear-gradient(145deg, #22272c, #565b60);
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    box-shadow: inset 0 1px 2px #ffffff55, 0 3px 9px #0003;
  }
  .ap-riko-dialog {
    position: fixed;
    inset: auto 10px calc(10px + env(safe-area-inset-bottom));
    width: min(560px, calc(100vw - 20px));
    max-width: none;
    max-height: min(790px, calc(100svh - 20px - env(safe-area-inset-top)));
    margin: 0 auto;
    padding: 0;
    overflow: hidden;
    border: 1px solid #ffffff78;
    border-radius: 27px;
    background: #f4f3f0f2;
    color: #191a1c;
    box-shadow: 0 24px 90px #0005;
  }
  [data-theme="dark"] .ap-riko-dialog {
    background: #191b1ef5;
    color: #f5f4f2;
    border-color: #ffffff25;
  }
  .ap-riko-dialog::backdrop { background: #10111488; -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }
  .ap-riko-shell { display: flex; flex-direction: column; max-height: inherit; min-height: min(590px, calc(100svh - 36px)); padding: 22px 20px calc(17px + env(safe-area-inset-bottom)); }
  .ap-riko-header { display: flex; justify-content: space-between; gap: 18px; align-items: start; }
  .ap-riko-header .ap-section-label { margin: 0 0 10px; font-size: 8px; letter-spacing: .15em; }
  .ap-riko-header h2 { margin: 0; font-size: 27px; font-weight: 500; letter-spacing: -.055em; }
  .ap-riko-close { width: 36px; height: 36px; border: 1px solid #8884; border-radius: 50%; background: transparent; color: inherit; font-size: 24px; cursor: pointer; }
  .ap-riko-thread { display: flex; flex-direction: column; gap: 10px; min-height: 118px; max-height: 35svh; overflow-y: auto; overscroll-behavior: contain; padding: 20px 2px 10px; }
  .ap-riko-bubble { align-self: flex-start; max-width: 91%; margin: 0; padding: 13px 15px; border-radius: 17px 17px 17px 5px; background: #ffffffc9; color: inherit; font-size: 14px; line-height: 1.55; box-shadow: 0 4px 14px #1111; }
  [data-theme="dark"] .ap-riko-bubble { background: #ffffff12; box-shadow: none; }
  .ap-riko-bubble.ap-riko-question { align-self: flex-end; border-radius: 17px 17px 5px 17px; background: #212326; color: #fff; }
  [data-theme="dark"] .ap-riko-bubble.ap-riko-question { background: #f2f1ef; color: #171819; }
  .ap-riko-status { min-height: 18px; margin: 0; color: var(--ap-detail, #777); font-size: 11px; }
  .ap-riko-prompts { display: flex; flex-wrap: wrap; gap: 8px; overflow: auto; padding: 8px 1px 5px; }
  .ap-riko-prompts button,.ap-riko-action,.ap-riko-offer a { border: 1px solid #8a8d9135; border-radius: 999px; background: #ffffffa8; color: inherit; font: inherit; text-decoration: none; cursor: pointer; }
  [data-theme="dark"] .ap-riko-prompts button,[data-theme="dark"] .ap-riko-action,[data-theme="dark"] .ap-riko-offer a { background: #ffffff10; border-color: #ffffff24; }
  .ap-riko-prompts button { padding: 9px 12px; font-size: 11px; line-height: 1.3; text-align: left; }
  .ap-riko-prompts button:disabled { opacity: .5; }
  .ap-riko-actions { display: grid; gap: 9px; padding-top: 9px; }
  .ap-riko-actions[hidden] { display: none; }
  .ap-riko-action { display: block; width: fit-content; padding: 11px 15px; font-size: 12px; }
  .ap-riko-offer { overflow: hidden; padding: 12px; border: 1px solid #898d9126; border-radius: 19px; background: #ffffff70; box-shadow: 0 8px 24px #11110a08; -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); }
  [data-theme="dark"] .ap-riko-offer { border-color: #ffffff18; background: #ffffff0a; box-shadow: 0 8px 24px #0002; }
  .ap-riko-offer-art { display: grid; place-items: center; height: 112px; margin: -2px -2px 12px; overflow: hidden; border-radius: 14px; background: radial-gradient(ellipse at 50% 62%, #d7e1e744, #ffffff16 66%, transparent); }
  [data-theme="dark"] .ap-riko-offer-art { background: radial-gradient(ellipse at 50% 62%, #90a5c020, #ffffff08 66%, transparent); }
  .ap-riko-offer-art img { width: 100%; height: 100%; object-fit: contain; }
  .ap-riko-offer-heading { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; }
  .ap-riko-offer h3 { margin: 0; font-size: 15px; font-weight: 550; letter-spacing: -.025em; }
  .ap-riko-offer p { margin: 6px 0 0; font-size: 11px; line-height: 1.5; color: var(--ap-detail, #777); }
  .ap-riko-offer .ap-riko-price { flex: 0 0 auto; margin: 0; font-size: 14px; font-weight: 600; color: inherit; }
  .ap-riko-offer .ap-riko-offer-description { margin-top: 7px; font-size: 12px; }
  .ap-riko-offer .ap-riko-offer-note { display: grid; gap: 2px; margin-top: 10px; padding-top: 9px; border-top: 1px solid #8882; }
  .ap-riko-offer-note strong { color: inherit; font-size: 10px; font-weight: 600; }
  .ap-riko-offer .ap-riko-offer-tax { font-size: 10px; }
  .ap-riko-offer-links { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 12px; }
  .ap-riko-offer a { display: inline-flex; align-items: center; min-height: 34px; padding: 8px 11px; font-size: 11px; }
  .ap-riko-offer .ap-riko-offer-primary { border-color: #222; background: #222; color: #fff; }
  [data-theme="dark"] .ap-riko-offer .ap-riko-offer-primary { border-color: #f2f1ef; background: #f2f1ef; color: #171819; }
  .ap-riko-offer .ap-riko-offer-terms { background: transparent; }
  .ap-riko-offer .ap-riko-offer-checkout-note { margin-top: 7px; font-size: 10px; }
  .ap-riko-footer { display: flex; justify-content: space-between; gap: 15px; margin-top: auto; padding-top: 13px; border-top: 1px solid #8883; }
  .ap-riko-footer a { color: inherit; font-size: 11px; text-underline-offset: 3px; }
  .ap-riko-launcher:focus-visible,.ap-riko-dialog button:focus-visible,.ap-riko-dialog a:focus-visible { outline: 2px solid #6387c2; outline-offset: 3px; }
}

@media (max-width: 380px) {
  .ap-contact-quick { gap: 8px; }
  .ap-contact-quick a { padding-inline: 12px; }
  .ap-riko-shell { padding-inline: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .ap-riko-launcher,.ap-contact-quick a { transition: none !important; }
}
