/* 注文ポータル CSS */
:root {
    /* ブランドカラー */
    --primary-color: #e67e22;
    --primary-dark: #d35400;
    --primary-light: #fff8f0;

    /* ステータスカラー */
    --status-completed: #27ae60;
    --status-cancelled: #e74c3c;

    /* スペーシング */
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;

    /* ボーダー半径 */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans JP', sans-serif;
    background: #f5f5f5;
    color: #333;
    padding-bottom: 100px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    padding: 0 15px;
}

/* ヘッダー */
.order-header {
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: #fff;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.shop-name {
    font-size: 1.3rem;
    font-weight: 700;
}

.customer-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    background: rgba(255,255,255,0.2);
    padding: 6px 12px;
    border-radius: 20px;
}

/* メイン */
.order-main {
    padding: 20px 0;
}

.order-notice {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: #fff;
    padding: 15px 20px;
    border-radius: 12px;
    margin-bottom: 25px;
    text-align: center;
}

.order-notice p {
    margin: 0;
    font-size: 0.95rem;
}

.order-notice strong {
    font-size: 1.1rem;
}

/* カテゴリ */
.menu-category {
    margin-bottom: 30px;
}

.category-title {
    font-size: 1.3rem;
    font-weight: 700;
    color: #333;
    padding: 10px 0;
    margin-bottom: 15px;
    border-bottom: 3px solid #e67e22;
    display: inline-block;
}

/* メニューグリッド */
.menu-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

@media (max-width: 600px) {
    .menu-grid {
        grid-template-columns: 1fr;
    }
}

@media (min-width: 900px) {
    .menu-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.menu-item {
    background: #fff;
    border-radius: var(--radius-md);
    overflow: hidden;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.menu-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 20px rgba(0,0,0,0.12);
}

.menu-image {
    height: 180px;
    overflow: hidden;
    background: #f0f0f0;
    position: relative;
}

.menu-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.menu-image-placeholder {
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ccc;
    font-size: 2rem;
}

.menu-info {
    padding: 15px;
    flex: 1;
}

.menu-name {
    font-size: 1.1rem;
    font-weight: 700;
    color: #333;
    margin-bottom: 5px;
}

.menu-description {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 10px;
    line-height: 1.4;
}

.menu-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: #e67e22;
}

/* 数量コントロール */
.menu-actions {
    padding: 10px 15px 15px;
    border-top: 1px solid #eee;
}

.quantity-control {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
}

.qty-btn {
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    transition: all 0.2s ease;
}

.qty-btn.minus {
    background: #eee;
    color: #666;
}

.qty-btn.plus {
    background: #e67e22;
    color: #fff;
}

.qty-btn:active {
    transform: scale(0.95);
}

.quantity {
    font-size: 1.3rem;
    font-weight: 700;
    min-width: 40px;
    text-align: center;
}

/* カートバー */
.cart-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #fff;
    box-shadow: 0 -4px 20px rgba(0,0,0,0.15);
    padding: 15px 0;
    transform: translateY(100%);
    transition: transform 0.3s ease;
    z-index: 200;
}

.cart-bar.show {
    transform: translateY(0);
}

.cart-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 15px;
}

.cart-summary {
    display: flex;
    align-items: center;
    gap: 15px;
}

.cart-count {
    font-size: 1rem;
    color: #666;
}

.cart-total {
    font-size: 1.4rem;
    font-weight: 700;
    color: #333;
}

.delivery-note {
    font-size: 0.85rem;
    color: #888;
}

.cart-button {
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: #fff;
    padding: 12px 25px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.cart-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(230, 126, 34, 0.4);
}

.cart-button.disabled {
    background: #ccc;
    pointer-events: none;
}

/* カートページ */
.cart-header {
    background: #fff;
    padding: 20px 0;
    border-bottom: 1px solid #eee;
    margin-bottom: 20px;
}

.cart-header h1 {
    font-size: 1.5rem;
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-items {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    margin-bottom: 20px;
}

.cart-item {
    display: flex;
    align-items: center;
    padding: 15px;
    border-bottom: 1px solid #eee;
    gap: 15px;
}

.cart-item:last-child {
    border-bottom: none;
}

.cart-item-image {
    width: 70px;
    height: 70px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
    background: #f0f0f0;
}

.cart-item-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.cart-item-info {
    flex: 1;
}

.cart-item-name {
    font-weight: 700;
    margin-bottom: 5px;
}

.cart-item-price {
    color: #888;
    font-size: 0.9rem;
}

.cart-item-qty {
    display: flex;
    align-items: center;
    gap: 10px;
}

.cart-item-qty .qty-btn {
    width: 36px;
    height: 36px;
}

.cart-item-qty .quantity {
    font-size: 1.1rem;
    min-width: 30px;
}

.cart-item-subtotal {
    font-weight: 700;
    font-size: 1.1rem;
    color: #e67e22;
    min-width: 80px;
    text-align: right;
}

/* 合計 */
.cart-summary-card {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    padding: 10px 0;
    border-bottom: 1px solid #eee;
}

.summary-row:last-child {
    border-bottom: none;
}

.summary-row.total {
    font-size: 1.3rem;
    font-weight: 700;
    color: #e67e22;
    padding-top: 15px;
    border-top: 2px solid #e67e22;
    margin-top: 10px;
}

.free-delivery-badge {
    background: #27ae60;
    color: #fff;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 0.8rem;
}

/* フォーム */
.order-form {
    background: #fff;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
}

.form-section-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #e67e22;
    display: flex;
    align-items: center;
    gap: 10px;
}

.form-group {
    margin-bottom: 20px;
}

.form-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #555;
}

.form-label .required {
    color: #e74c3c;
    margin-left: 5px;
}

.form-control {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    transition: border-color 0.3s ease;
}

.form-control:focus {
    outline: none;
    border-color: #e67e22;
}

.form-select {
    appearance: none;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%23666' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E") no-repeat right 15px center;
    background-color: #fff;
    padding-right: 40px;
}

.form-radio-group {
    display: flex;
    gap: 20px;
}

.form-radio {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 12px 20px;
    border: 2px solid #ddd;
    border-radius: 8px;
    flex: 1;
    transition: all 0.3s ease;
}

.form-radio:has(input:checked) {
    border-color: #e67e22;
    background: #fff8f0;
}

.form-radio input {
    width: 20px;
    height: 20px;
    accent-color: #e67e22;
}

/* 送信ボタン */
.submit-btn {
    width: 100%;
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: #fff;
    border: none;
    padding: 18px;
    border-radius: 12px;
    font-size: 1.2rem;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(230, 126, 34, 0.4);
}

.submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 完了ページ */
.complete-card {
    background: #fff;
    border-radius: var(--radius-lg);
    padding: 40px 30px;
    text-align: center;
    margin-top: 30px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.08);
}

.complete-icon {
    width: 80px;
    height: 80px;
    background: var(--status-completed);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5rem;
    margin: 0 auto 20px;
}

.complete-title {
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #333;
}

.complete-message {
    color: #666;
    margin-bottom: 30px;
    line-height: 1.6;
}

.order-number {
    background: var(--primary-light);
    padding: 15px 20px;
    border-radius: var(--radius-sm);
    font-size: 1.2rem;
    margin-bottom: 30px;
    border-left: 4px solid var(--primary-color);
}

.order-number span {
    font-weight: 700;
    color: var(--primary-color);
}

.complete-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

/* 注文内容・配達情報カード */
.order-detail-card {
    text-align: left;
    border-left: 4px solid var(--primary-color);
    margin-bottom: 20px;
}

.order-detail-card .section-title {
    margin-bottom: 15px;
    font-size: 1rem;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.order-detail-card .section-title i {
    color: var(--primary-color);
}

/* テキストスタイル */
.text-muted-small {
    color: #888;
    font-size: 0.85rem;
}

.text-primary-small {
    color: var(--primary-color);
    font-size: 0.85rem;
}

.text-right {
    text-align: right;
}

.btn {
    padding: 15px 30px;
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    transition: all 0.3s ease;
}

.btn-primary {
    background: linear-gradient(135deg, #e67e22, #d35400);
    color: #fff;
}

.btn-secondary {
    background: #fff;
    color: #333;
    border: 2px solid #ddd;
}

/* 追跡ページ */
.track-card {
    background: #fff;
    border-radius: 16px;
    padding: 30px;
    margin-top: 20px;
}

.track-header {
    text-align: center;
    margin-bottom: 30px;
}

.track-order-number {
    font-size: 1.1rem;
    color: #666;
}

.track-order-number span {
    font-weight: 700;
    color: #e67e22;
}

/* ステータスステッパー */
.status-stepper {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    position: relative;
}

.status-stepper::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 10%;
    right: 10%;
    height: 3px;
    background: #eee;
    z-index: 1;
}

.status-step {
    text-align: center;
    position: relative;
    z-index: 2;
    flex: 1;
}

.status-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: #eee;
    color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    margin: 0 auto 10px;
    transition: all 0.3s ease;
}

.status-step.active .status-icon,
.status-step.completed .status-icon {
    background: #27ae60;
    color: #fff;
}

.status-step.current .status-icon {
    background: #e67e22;
    color: #fff;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(230, 126, 34, 0.4); }
    50% { box-shadow: 0 0 0 10px rgba(230, 126, 34, 0); }
}

.status-label {
    font-size: 0.85rem;
    color: #999;
}

.status-step.active .status-label,
.status-step.completed .status-label,
.status-step.current .status-label {
    color: #333;
    font-weight: 600;
}

.status-time {
    font-size: 0.75rem;
    color: #888;
    margin-top: 5px;
}

/* 追跡詳細 */
.track-details {
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.track-section {
    margin-bottom: 20px;
}

.track-section-title {
    font-weight: 700;
    margin-bottom: 10px;
    color: #555;
}

.track-item-list {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
}

.track-item {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #eee;
}

.track-item:last-child {
    border-bottom: none;
}

/* 戻るリンク */
.back-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #666;
    text-decoration: none;
    padding: 10px 0;
}

.back-link:hover {
    color: #e67e22;
}

/* レスポンシブ - 追加調整 */
@media (max-width: 600px) {
    .header-content {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }

    .cart-bar-content {
        flex-direction: column;
    }

    .cart-summary {
        width: 100%;
        justify-content: center;
    }

    .cart-button {
        width: 100%;
        justify-content: center;
    }

    .form-radio-group {
        flex-direction: column;
    }

    .cart-item {
        flex-wrap: wrap;
    }

    .cart-item-subtotal {
        width: 100%;
        text-align: left;
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px dashed #eee;
    }

    .status-stepper {
        flex-wrap: wrap;
        gap: 10px;
    }

    .status-stepper::before {
        display: none;
    }

    .status-step {
        flex: 0 0 30%;
    }
}
