/* 가맹점 — Figma 2176:103 골격 + 공통 로고 + 카테고리 폴리시 */
.r2go-page--franchise {
    display: flex;
    flex-direction: column;
    gap: 0;
    width: 100%;
    min-width: 0;
    padding-top: 14px;
    padding-bottom: 28px;
    background: #fff;
}
.r2go-page--franchise a {
    text-decoration: none !important;
}

.r2go-franchise__toolbar {
    margin: 0 0 16px;
}
.r2go-franchise__heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 14px;
}
.r2go-franchise__eyebrow,
.r2go-franchise__title,
.r2go-franchise__subtitle,
.r2go-franchise__filter-label {
    margin: 0;
}
.r2go-franchise__eyebrow {
    color: #7c3aed;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .12em;
}
.r2go-franchise__title {
    margin-top: 3px;
    color: #17121f;
    font-size: 24px;
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -.04em;
}
.r2go-franchise__subtitle {
    margin-top: 4px;
    color: #8b8494;
    font-size: 12px;
    line-height: 1.4;
}
.r2go-franchise__view-toggle {
    min-height: 32px;
    padding: 0 12px;
    border: 1px solid #e6d9ee;
    border-radius: 16px;
    background: #fff;
    color: #5f0080;
    font: inherit;
    font-size: 12px;
    font-weight: 600;
}
.r2go-franchise__search {
    display: flex;
    align-items: center;
    gap: 8px;
    height: 42px;
    padding: 0 12px;
    border: 1px solid #e4ddeb;
    border-radius: 12px;
    background: #fbfaff;
    color: #9b91a3;
}
.r2go-franchise__search-icon {
    font-size: 22px;
    line-height: 1;
    transform: rotate(-20deg);
}
.r2go-franchise__search input {
    min-width: 0;
    flex: 1;
    border: 0;
    outline: 0;
    background: transparent;
    color: #21172b;
    font: inherit;
    font-size: 13px;
}
.r2go-franchise__search input::placeholder { color: #aaa1b2; }
.r2go-franchise__search-count {
    color: #8b8494;
    font-size: 11px;
}
.r2go-franchise__filter-block { margin-bottom: 10px; }
.r2go-franchise__filter-label {
    margin-bottom: 7px;
    color: #6f6878;
    font-size: 11px;
    font-weight: 700;
}
.r2go-franchise__type-filters {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 6px;
}
.r2go-franchise__type {
    height: 34px;
    border: 1px solid #e9e5ec;
    border-radius: 9px;
    background: #fff;
    color: #756d7f;
    font: inherit;
    font-size: 12px;
    font-weight: 600;
}
.r2go-franchise__type.is-active {
    border-color: #5f0080;
    background: #5f0080;
    color: #fff;
    box-shadow: 0 4px 10px rgba(95, 0, 128, .18);
}

/* 업종 레일 — 셀러샵과 동일한 좌우 이동 카테고리 */
.r2go-franchise__category-heading {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    margin: 18px 0 9px;
}
.r2go-franchise__category-heading p {
    margin: 0;
    color: #2c2334;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: -0.03em;
}
.r2go-franchise__category-heading span {
    color: #a29aa9;
    font-size: 10px;
    font-weight: 500;
}
.r2go-franchise__cats-wrap {
    position: relative;
    display: flex;
    align-items: stretch;
    margin: 0 -16px 16px;
    width: calc(100% + 32px);
    min-width: 0;
}
.r2go-franchise__cats {
    display: flex;
    flex: 1 1 auto;
    gap: 0;
    overflow-x: auto;
    margin: 0;
    padding: 0 28px 8px;
    list-style: none;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    touch-action: pan-x;
    user-select: none;
    -webkit-user-select: none;
    cursor: grab;
}
.r2go-franchise__cats.is-dragging { cursor: grabbing; }
.r2go-franchise__cats::-webkit-scrollbar {
    display: none;
}
.r2go-franchise__cat {
    flex: 0 0 auto;
    margin: 0;
}
.r2go-franchise__cats-arrow {
    position: absolute;
    top: 0;
    z-index: 2;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 35px;
    padding: 0;
    border: 0;
    background: linear-gradient(90deg, #fff 55%, rgba(255,255,255,0));
    color: #5f0080;
    font-size: 22px;
    font-weight: 700;
    line-height: 1;
    cursor: pointer;
}
.r2go-franchise__cats-arrow--prev { left: 0; }
.r2go-franchise__cats-arrow--next {
    right: 0;
    background: linear-gradient(270deg, #fff 55%, rgba(255,255,255,0));
}
.r2go-franchise__cats-arrow:disabled,
.r2go-franchise__cats-wrap.is-no-overflow .r2go-franchise__cats-arrow {
    opacity: .25;
    pointer-events: none;
}
.r2go-franchise__cat-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 35px;
    padding: 0 14px;
    border: 0;
    background: transparent;
    color: #817887;
    text-decoration: none;
    text-align: center;
    font-family: Pretendard, "Noto Sans KR", sans-serif;
    font-size: 13px;
    font-weight: 600;
    line-height: 15px;
    letter-spacing: -0.03em;
    transition: color 160ms ease, transform 120ms ease;
    -webkit-tap-highlight-color: transparent;
    appearance: none;
    font-family: inherit;
    cursor: pointer;
}
.r2go-franchise__cat-link:active {
    transform: scale(0.97);
}
.r2go-franchise__cat-link.is-active {
    color: #5f0080;
    font-weight: 700;
}
.r2go-franchise__cat-link.is-active::after {
    content: "";
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 0;
    height: 3px;
    border-radius: 2px;
    background: #5f0080;
}
.r2go-franchise__cat-icon {
    display: none;
}
.r2go-franchise__cat-line {
    display: block;
}

/* 매장 리스트 */
.r2go-franchise__list {
    list-style: none;
    margin: 0;
    padding: 0;
}
.r2go-franchise__item {
    animation: r2go-franchise-fade 220ms ease;
}
.r2go-franchise__item.is-hidden {
    display: none;
}
.r2go-franchise__item:not(.is-hidden) + .r2go-franchise__item:not(.is-hidden) {
    border-top: 8px solid rgba(156, 163, 175, 0.2);
}
@keyframes r2go-franchise-fade {
    from {
        opacity: 0.35;
        transform: translateY(4px);
    }
    to {
        opacity: 1;
        transform: none;
    }
}
@media (prefers-reduced-motion: reduce) {
    .r2go-franchise__cat-link,
    .r2go-franchise__item {
        transition: none;
        animation: none;
    }
    .r2go-franchise__cat-link:active {
        transform: none;
    }
}

.r2go-franchise__card {
    display: block;
    text-decoration: none;
    color: inherit;
}
.r2go-franchise__media {
    width: calc(100% + 40px);
    margin: 0 -20px;
    overflow: hidden;
    background: #e8edf3;
}
.r2go-franchise__photo {
    display: block;
    width: 100%;
    aspect-ratio: 440 / 304;
    max-height: 320px;
    object-fit: cover;
    background: #e5e7eb;
}
.r2go-franchise__photo-fallback {
    display: flex;
    align-items: flex-end;
    justify-content: flex-start;
    width: 100%;
    aspect-ratio: 440 / 304;
    max-height: 320px;
    padding: 22px 20px;
    background:
        linear-gradient(180deg, rgba(17, 17, 17, 0) 42%, rgba(17, 17, 17, 0.42) 100%),
        radial-gradient(120% 80% at 12% 18%, rgba(255, 255, 255, 0.55), transparent 55%),
        var(--r2go-fallback-tone, #e5e7eb);
}
.r2go-franchise__photo-fallback-label {
    font-family: "Gmarket Sans", Pretendard, sans-serif;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.25;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}
.r2go-franchise__body {
    padding: 14px 0 20px;
}
.r2go-franchise__badge-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}
.r2go-franchise__badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 20px;
    padding: 0 10px;
    border-radius: 10px;
    background: #d0e3ff;
    color: #5f0080;
    font-size: 11px;
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.02em;
}
.r2go-franchise__title-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}
.r2go-franchise__name {
    margin: 0;
    font-family: Pretendard, "Noto Sans KR", sans-serif;
    font-size: 20px;
    font-weight: 700;
    line-height: 24px;
    letter-spacing: -0.03em;
    color: #111;
}
.r2go-franchise__points {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 15px;
    padding: 0 8px;
    border: 0.5px solid #c64545;
    border-radius: 10px;
    color: #c64545;
    font-size: 10px;
    font-weight: 400;
    line-height: 1;
}
.r2go-franchise__type-badge {
    display: inline-flex;
    align-items: center;
    min-height: 15px;
    padding: 0 7px;
    border-radius: 9px;
    background: #f1edf4;
    color: #756d7f;
    font-size: 10px;
    font-weight: 600;
    line-height: 1;
}
.r2go-franchise__tagline {
    margin: 0 0 12px;
    font-size: 10px;
    font-weight: 700;
    line-height: 1.4;
    letter-spacing: -0.02em;
    color: #c55200;
}
.r2go-franchise__meta {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0;
    padding: 0;
}
.r2go-franchise__meta-row {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}
.r2go-franchise__meta-icon {
    display: block;
    width: 17px;
    height: 17px;
    margin-top: 3px;
    flex-shrink: 0;
    object-fit: contain;
    opacity: 0.88;
}
.r2go-franchise__meta-row:first-child .r2go-franchise__meta-icon {
    width: 14px;
    height: 21px;
    aspect-ratio: 14 / 21;
    margin-left: 1px;
}
.r2go-franchise__meta-text {
    flex: 1;
    min-width: 0;
    margin: 0;
    font-size: 14px;
    font-weight: 400;
    line-height: 24px;
    letter-spacing: -0.02em;
    color: #111;
}
.r2go-franchise__transit {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-top: 2px;
}
.r2go-franchise__subway {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 16px;
    padding: 0 8px;
    border-radius: 5px;
    background: #0ccf0c;
    color: #fff;
    font-size: 12px;
    font-weight: 400;
    line-height: 1;
}
.r2go-franchise__subway-note {
    font-size: 12px;
    color: #111;
    line-height: 24px;
    letter-spacing: -0.02em;
}
.r2go-franchise__empty {
    margin: 28px 0;
    padding: 28px 16px;
    text-align: center;
    border-radius: 14px;
    background: var(--r2go-surface-soft, #f3f4f6);
    color: var(--r2go-body, #374151);
    font-size: 14px;
}
.r2go-franchise__empty[hidden] {
    display: none !important;
}
.r2go-franchise__no-results {
    margin: 24px 0;
    padding: 28px 16px;
    border: 1px solid #eee8f2;
    border-radius: 14px;
    background: #fbfaff;
    color: #756d7f;
    text-align: center;
    font-size: 13px;
}
.r2go-franchise__no-results[hidden] { display: none !important; }

body.r2go-franchise-page {
    overflow: hidden;
}
body.r2go-franchise-page .shell {
    min-height: 0;
    overflow-x: hidden;
    overflow-y: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
}
body.r2go-franchise-page .shell::-webkit-scrollbar {
    width: 0;
    height: 0;
    display: none;
}

.r2go-franchise__map {
    width: 100%;
    height: 180px;
    margin: 8px 0 4px;
    border-radius: 12px;
    overflow: hidden;
    background: #e2e8f0;
}

/* ==========================================================================
   스마트오더 메뉴 & 가맹점주 메뉴 관리 — Pretendard Variable & Weight Diet
   ========================================================================== */
.r2go-smart-order {
    margin-top: 20px;
    padding-bottom: 90px;
}
.r2go-smart-order__header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
    gap: 10px;
}
.r2go-smart-order__title-wrap {
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.r2go-smart-order__title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: -0.02em;
}
.r2go-smart-order__subtitle {
    margin: 0;
    font-size: 12px;
    font-weight: 400;
    color: #64748b;
}

/* 가맹점주 전용 메뉴 등록 버튼 */
.r2go-owner-menu-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 13px;
    background: #00c73c;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: background 0.18s ease, transform 0.1s ease;
    white-space: nowrap;
}
.r2go-owner-menu-btn:hover {
    background: #00b336;
    color: #ffffff;
}
.r2go-owner-menu-btn:active {
    transform: scale(0.98);
}

/* 가맹점주 메뉴 입력 폼 */
.r2go-owner-form-box {
    margin-bottom: 16px;
    padding: 16px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
}
.r2go-owner-form-box__title {
    margin: 0 0 12px;
    font-size: 15px;
    font-weight: 600;
    color: #0f172a;
}
.r2go-owner-form-box .r2go-form-row {
    margin-bottom: 10px;
}
.r2go-owner-form-box label {
    display: block;
    margin-bottom: 4px;
    font-size: 12px;
    font-weight: 500;
    color: #475569;
}
.r2go-owner-form-box input {
    width: 100%;
    height: 40px;
    padding: 0 12px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #ffffff;
    font-size: 14px;
    font-weight: 400;
    color: #0f172a;
    box-sizing: border-box;
}
.r2go-owner-form-box input:focus {
    outline: none;
    border-color: #00c73c;
    box-shadow: 0 0 0 3px rgba(0, 199, 60, 0.12);
}
.r2go-owner-form-box__actions {
    display: flex;
    gap: 8px;
    margin-top: 14px;
}
.r2go-owner-form-box__submit {
    flex: 1;
    height: 40px;
    background: #00c73c;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}
.r2go-owner-form-box__cancel {
    height: 40px;
    padding: 0 16px;
    background: #ffffff;
    color: #64748b;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
}

/* 메뉴 아이템 카드 */
.r2go-menu-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.r2go-menu-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.03);
    transition: border-color 0.15s ease;
}
.r2go-menu-card:hover {
    border-color: #cbd5e1;
}
.r2go-menu-card__info {
    flex: 1;
    min-width: 0;
    padding-right: 12px;
}
.r2go-menu-card__title {
    margin: 0 0 3px;
    font-size: 15px;
    font-weight: 600;
    color: #0f172a;
    letter-spacing: -0.01em;
}
.r2go-menu-card__summary {
    margin: 0 0 6px;
    font-size: 12px;
    font-weight: 400;
    color: #64748b;
    line-height: 1.4;
}
.r2go-menu-card__price {
    font-size: 15px;
    font-weight: 600;
    color: #059669;
    letter-spacing: -0.01em;
}
.r2go-menu-card__controls {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
    flex-shrink: 0;
}

/* 점주 삭제 버튼 */
.r2go-menu-card__del-btn {
    padding: 3px 8px;
    background: transparent;
    color: #94a3b8;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 400;
    cursor: pointer;
}
.r2go-menu-card__del-btn:hover {
    color: #ef4444;
    border-color: #fca5a5;
    background: #fef2f2;
}

/* 스마트오더 수량 선택기 (+ / -) */
.r2go-qty-selector {
    display: inline-flex;
    align-items: center;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: #f8fafc;
    overflow: hidden;
}
.r2go-qty-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #ffffff;
    color: #1e293b;
    border: none;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
    transition: background 0.12s ease;
}
.r2go-qty-btn:hover {
    background: #f1f5f9;
}
.r2go-qty-btn:active {
    background: #e2e8f0;
}
.r2go-qty-count {
    min-width: 32px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #0f172a;
    padding: 0 4px;
}

/* 하단 플로팅 스마트오더 결제 바 */
.r2go-order-bar {
    position: fixed;
    bottom: 56px;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 10px 16px;
    background: rgba(15, 23, 42, 0.94);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: space-between;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.14);
    transform: translateY(120%);
    transition: transform 0.24s cubic-bezier(0.16, 1, 0.3, 1);
}
.r2go-order-bar.is-visible {
    transform: translateY(0);
}
.r2go-order-bar__info {
    color: #ffffff;
}
.r2go-order-bar__count {
    font-size: 12px;
    font-weight: 400;
    color: #94a3b8;
    margin-bottom: 2px;
}
.r2go-order-bar__total {
    font-size: 17px;
    font-weight: 600;
    color: #34d399;
}
.r2go-order-bar__btn {
    height: 40px;
    padding: 0 20px;
    background: #00c73c;
    color: #ffffff;
    border: none;
    border-radius: 9999px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(0, 199, 60, 0.35);
    transition: background 0.15s ease, transform 0.1s ease;
}
.r2go-order-bar__btn:hover {
    background: #00b336;
}
.r2go-order-bar__btn:active {
    transform: scale(0.97);
}

@media (min-width: 600px) {
    body.r2go-app-page:not(.is-intro) .r2go-order-bar {
        position: absolute !important;
        left: 0 !important;
        right: 0 !important;
        width: 100% !important;
        bottom: 26px !important;
        z-index: 250 !important;
    }
}
