@import url('https://fonts.googleapis.com/css2?family=Playfair+Display:wght@400;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
    --bg:        #faf7f2;
    --bg-card:   #ffffff;
    --bg-warm:   #f5ebe0;
    --text:      #2d2013;
    --text-dim:  #8a7560;
    --accent:    #d4763c;
    --accent-h:  #c06430;
    --green:     #5a8a5e;
    --green-l:   #e8f0e8;
    --red:       #c44d4d;
    --red-l:     #fdeaea;
    --gold:      #d4a03c;
    --gold-l:    #fff8e8;
    --border:    #e8ddd0;
    --shadow:    0 2px 12px rgba(45,32,19,0.06);
    --shadow-lg: 0 8px 32px rgba(45,32,19,0.10);
    --radius:    16px;
    --radius-sm: 10px;
}

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: 'Playfair Display', serif; }

.app-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ── Header ── */
.app-header {
    padding: 24px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    margin-bottom: 32px;
}

.app-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
}

.app-logo .logo-icon { font-size: 36px; }

.app-logo h1 {
    font-size: 28px;
    font-weight: 700;
    color: var(--text);
}

.app-logo h1 span { color: var(--accent); }

.header-actions { display: flex; gap: 10px; align-items: center; }

.btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    border-radius: var(--radius-sm);
    border: none;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
}
.btn-primary:hover { background: var(--accent-h); transform: translateY(-1px); }

.btn-secondary {
    background: var(--bg-warm);
    color: var(--text);
    border: 1px solid var(--border);
}
.btn-secondary:hover { background: var(--border); }

.btn-ghost {
    background: transparent;
    color: var(--text-dim);
    padding: 8px 12px;
}
.btn-ghost:hover { color: var(--accent); }

.btn-danger { background: var(--red); color: #fff; }
.btn-danger:hover { background: #b04040; }

.btn-sm { padding: 6px 14px; font-size: 13px; }
.btn-icon { padding: 8px; font-size: 20px; }

/* ── Search & Filter Bar ── */
.filter-bar {
    display: flex;
    gap: 12px;
    margin-bottom: 28px;
    flex-wrap: wrap;
    align-items: center;
}

.search-box {
    flex: 1;
    min-width: 250px;
    position: relative;
}

.search-box input {
    width: 100%;
    padding: 12px 16px 12px 44px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 15px;
    background: var(--bg-card);
    color: var(--text);
    transition: border-color 0.2s;
    font-family: 'Inter', sans-serif;
}

.search-box input:focus { border-color: var(--accent); outline: none; }

.search-box .search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 18px;
    color: var(--text-dim);
}

.category-pills {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.pill {
    padding: 8px 18px;
    border-radius: 50px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text-dim);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    font-family: 'Inter', sans-serif;
}

.pill:hover { border-color: var(--accent); color: var(--accent); }
.pill.active { background: var(--accent); color: #fff; border-color: var(--accent); }

/* ── Recipe Grid ── */
.recipe-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.recipe-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s;
    position: relative;
}

.recipe-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.card-image {
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 72px;
    position: relative;
}

.card-image .bg-pattern {
    position: absolute;
    inset: 0;
    opacity: 0.06;
    background: repeating-linear-gradient(
        45deg,
        var(--text) 0,
        var(--text) 1px,
        transparent 0,
        transparent 16px
    );
}

.card-fav {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255,255,255,0.85);
    border: none;
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    backdrop-filter: blur(8px);
}

.card-fav:hover { transform: scale(1.1); }
.card-fav.active { color: var(--red); }

.card-ai-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    padding: 4px 10px;
    background: rgba(212,118,60,0.9);
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    border-radius: 6px;
    backdrop-filter: blur(8px);
}

.card-body { padding: 18px; }

.card-body h3 {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 6px;
    line-height: 1.3;
}

.card-body p {
    font-size: 13px;
    color: var(--text-dim);
    line-height: 1.5;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.card-meta {
    display: flex;
    gap: 14px;
    margin-top: 14px;
    padding-top: 14px;
    border-top: 1px solid var(--border);
    font-size: 12px;
    color: var(--text-dim);
}

.card-meta span { display: flex; align-items: center; gap: 4px; }

.difficulty-badge {
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.diff-Easy { background: var(--green-l); color: var(--green); }
.diff-Medium { background: var(--gold-l); color: var(--gold); }
.diff-Hard { background: var(--red-l); color: var(--red); }

.card-tags {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.card-tags .tag {
    padding: 3px 10px;
    background: var(--bg-warm);
    border-radius: 50px;
    font-size: 11px;
    color: var(--text-dim);
}

/* ── Empty State ── */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-dim);
}

.empty-state .empty-icon { font-size: 64px; margin-bottom: 16px; }
.empty-state h3 { font-size: 22px; margin-bottom: 8px; color: var(--text); }
.empty-state p { font-size: 15px; }

/* ── Recipe Detail View ── */
.recipe-detail {
    max-width: 800px;
    margin: 0 auto;
}

.detail-header {
    text-align: center;
    margin-bottom: 36px;
}

.detail-emoji {
    font-size: 80px;
    display: block;
    margin-bottom: 16px;
}

.detail-header h1 {
    font-size: 36px;
    margin-bottom: 8px;
}

.detail-header .desc {
    font-size: 16px;
    color: var(--text-dim);
    line-height: 1.6;
    max-width: 600px;
    margin: 0 auto;
}

.detail-meta {
    display: flex;
    justify-content: center;
    gap: 24px;
    margin: 24px 0 36px;
    flex-wrap: wrap;
}

.meta-item {
    text-align: center;
    padding: 16px 24px;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    min-width: 100px;
}

.meta-item .meta-icon { font-size: 24px; display: block; margin-bottom: 4px; }
.meta-item .meta-label { font-size: 11px; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.5px; }
.meta-item .meta-value { font-size: 16px; font-weight: 600; }

.detail-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 36px;
}

.section-title {
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title .section-icon { font-size: 22px; }

/* Ingredients */
.ingredients-section {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    padding: 28px;
    margin-bottom: 36px;
}

.ingredient-list { list-style: none; }

.ingredient-list li {
    display: flex;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
    font-size: 15px;
}

.ingredient-list li:last-child { border-bottom: none; }

.ingredient-list li .check-circle {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid var(--border);
    margin-right: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.2s;
}

.ingredient-list li .check-circle:hover { border-color: var(--accent); }
.ingredient-list li .check-circle.checked {
    background: var(--green);
    border-color: var(--green);
    color: #fff;
    font-size: 14px;
}

.ingredient-list li.checked-item { opacity: 0.5; text-decoration: line-through; }

.ingredient-amount {
    font-weight: 600;
    min-width: 80px;
    color: var(--accent);
}

.ingredient-name { flex: 1; }
.ingredient-note { color: var(--text-dim); font-size: 13px; font-style: italic; margin-left: 8px; }

/* Steps */
.steps-section { margin-bottom: 36px; }

.step-card {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    align-items: flex-start;
}

.step-number {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: var(--accent);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
    flex-shrink: 0;
}

.step-content {
    flex: 1;
    background: var(--bg-card);
    border-radius: var(--radius-sm);
    border: 1px solid var(--border);
    padding: 20px;
}

.step-content h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    font-family: 'Inter', sans-serif;
}

.step-content p { font-size: 14px; color: var(--text-dim); line-height: 1.7; }

.step-time {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    font-size: 12px;
    color: var(--accent);
    font-weight: 500;
}

/* Tips */
.tips-box {
    background: var(--gold-l);
    border: 1px solid #e8d8b8;
    border-radius: var(--radius-sm);
    padding: 20px 24px;
    margin-bottom: 36px;
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.tips-box .tip-icon { font-size: 24px; flex-shrink: 0; }
.tips-box p { font-size: 14px; line-height: 1.7; color: var(--text); }

/* ── AI Generate Modal ── */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
    padding: 20px;
}

.modal {
    background: var(--bg-card);
    border-radius: var(--radius);
    width: 100%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.modal-header {
    padding: 24px 28px;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-header h2 { font-size: 22px; }

.modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: var(--bg-warm);
    border-radius: 50%;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.modal-close:hover { background: var(--border); }

.modal-body { padding: 28px; }

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

.form-group label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 8px;
    color: var(--text);
}

.form-group textarea,
.form-group input,
.form-group select {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    font-size: 14px;
    background: var(--bg);
    color: var(--text);
    font-family: 'Inter', sans-serif;
    transition: border-color 0.2s;
}

.form-group textarea:focus,
.form-group input:focus,
.form-group select:focus { border-color: var(--accent); outline: none; }

.form-group textarea { resize: vertical; min-height: 100px; line-height: 1.6; }
.form-hint { font-size: 12px; color: var(--text-dim); margin-top: 4px; }

.modal-footer {
    padding: 20px 28px;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ── AI Generating Animation ── */
.ai-loading {
    text-align: center;
    padding: 48px 20px;
}

.ai-loading .cooking-anim {
    font-size: 56px;
    animation: cooking 1.2s ease-in-out infinite;
}

@keyframes cooking {
    0%, 100% { transform: rotate(-5deg) scale(1); }
    50% { transform: rotate(5deg) scale(1.1); }
}

.ai-loading p { margin-top: 16px; font-size: 15px; color: var(--text-dim); }

.dots::after {
    content: '';
    animation: dots 1.5s steps(4) infinite;
}

@keyframes dots {
    0% { content: ''; }
    25% { content: '.'; }
    50% { content: '..'; }
    75% { content: '...'; }
}

/* ── AI Preview ── */
.ai-preview {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 20px;
    margin-bottom: 20px;
}

.ai-preview h4 {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 12px;
    color: var(--accent);
}

.preview-details { font-size: 13px; color: var(--text-dim); line-height: 1.8; }

/* ── Settings ── */
.settings-page {
    max-width: 600px;
    margin: 0 auto;
}

.settings-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 28px;
    margin-bottom: 20px;
}

.settings-card h3 {
    font-size: 18px;
    margin-bottom: 16px;
    font-family: 'Inter', sans-serif;
}

.api-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    margin-bottom: 12px;
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
}

.status-dot.active { background: var(--green); }
.status-dot.inactive { background: var(--red); }

/* ── Toast ── */
.toast-container {
    position: fixed;
    bottom: 24px;
    right: 24px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.toast {
    padding: 14px 20px;
    background: var(--text);
    color: #fff;
    border-radius: var(--radius-sm);
    font-size: 14px;
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease;
    max-width: 360px;
}

.toast.success { background: var(--green); }
.toast.error { background: var(--red); }

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* ── Back button ── */
.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 16px;
    border: none;
    background: none;
    color: var(--text-dim);
    font-size: 14px;
    cursor: pointer;
    margin-bottom: 24px;
    transition: color 0.2s;
    font-family: 'Inter', sans-serif;
}

.back-btn:hover { color: var(--accent); }

/* ── Responsive ── */
@media (max-width: 768px) {
    .app-header { flex-direction: column; gap: 12px; text-align: center; }
    .filter-bar { flex-direction: column; }
    .search-box { min-width: 100%; }
    .category-pills { justify-content: center; }
    .recipe-grid { grid-template-columns: 1fr; }
    .detail-header h1 { font-size: 28px; }
    .detail-meta { gap: 10px; }
    .meta-item { padding: 12px 16px; }
    .step-card { flex-direction: column; gap: 12px; }
    .step-number { width: 36px; height: 36px; font-size: 15px; }
    .ingredient-amount { min-width: 60px; font-size: 13px; }
}

/* ── Color themes per category ── */
.cat-Main-Course .card-image { background: linear-gradient(135deg, #fff5ee 0%, #ffe4d0 100%); }
.cat-Appetizer .card-image  { background: linear-gradient(135deg, #f0f7ee 0%, #d8ecd0 100%); }
.cat-Dessert .card-image    { background: linear-gradient(135deg, #fef0f5 0%, #f5d0e0 100%); }
.cat-Breakfast .card-image  { background: linear-gradient(135deg, #fff8e8 0%, #ffe8b8 100%); }
.cat-Soup .card-image       { background: linear-gradient(135deg, #eef5ff 0%, #d0e4ff 100%); }
.cat-Salad .card-image      { background: linear-gradient(135deg, #eefaee 0%, #c8e8c8 100%); }
.cat-Snack .card-image      { background: linear-gradient(135deg, #faf0ff 0%, #e8d0f8 100%); }
.cat-Drink .card-image      { background: linear-gradient(135deg, #e8f8ff 0%, #c0e8f8 100%); }
.cat-Sauce .card-image      { background: linear-gradient(135deg, #fff5f0 0%, #f8d8c8 100%); }
.cat-Bread .card-image      { background: linear-gradient(135deg, #fdf5e8 0%, #f0dbb8 100%); }
.cat-Side-Dish .card-image  { background: linear-gradient(135deg, #f5f0ff 0%, #e0d0f8 100%); }
.cat-Other .card-image      { background: linear-gradient(135deg, #f0f0f0 0%, #e0e0e0 100%); }

/* ── Manual Recipe Form ── */
.ingredient-row,
.step-row {
    display: flex;
    gap: 8px;
    margin-bottom: 8px;
    align-items: center;
}

.ingredient-row input { flex: 1; }
.step-row textarea { flex: 1; }

.add-row-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 14px;
    border: 1px dashed var(--border);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--accent);
    cursor: pointer;
    font-size: 13px;
    font-family: 'Inter', sans-serif;
    transition: all 0.2s;
}

.add-row-btn:hover { background: var(--bg-warm); border-color: var(--accent); }

.remove-row {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: none;
    background: var(--red-l);
    color: var(--red);
    font-size: 16px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.remove-row:hover { background: var(--red); color: #fff; }

/* ── Tab styles for create modal ── */
.create-tabs {
    display: flex;
    border-bottom: 2px solid var(--border);
    margin-bottom: 24px;
}

.create-tab {
    flex: 1;
    padding: 12px;
    text-align: center;
    border: none;
    background: none;
    font-size: 14px;
    font-weight: 500;
    color: var(--text-dim);
    cursor: pointer;
    position: relative;
    font-family: 'Inter', sans-serif;
    transition: color 0.2s;
}

.create-tab:hover { color: var(--text); }

.create-tab.active {
    color: var(--accent);
}

.create-tab.active::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--accent);
}

.emoji-picker {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 8px;
}

.emoji-option {
    width: 40px;
    height: 40px;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: var(--bg);
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.emoji-option:hover { border-color: var(--accent); transform: scale(1.1); }
.emoji-option.selected { border-color: var(--accent); background: var(--bg-warm); }

/* Nutrition row for form */
.nutrition-row {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
}

.nutrition-row .form-group { margin-bottom: 0; }




/* ── Recipe Photo Images ── */
.card-image.has-photo {
    padding: 0;
    overflow: hidden;
}
.card-photo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.3s ease;
}
.recipe-card:hover .card-photo {
    transform: scale(1.05);
}
.detail-photo {
    width: 100%;
    max-height: 350px;
    object-fit: cover;
    border-radius: 16px;
    margin-bottom: 20px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
}


/* ── Auth Modal (light theme) ── */
.login-card {
    background: var(--bg-card);
    border-radius: var(--radius);
    padding: 2.5rem;
    width: 380px;
    text-align: center;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border);
}
.login-card h2 {
    margin: .5rem 0 .5rem;
    color: var(--text);
    font-size: 22px;
}
.login-card input[type="text"],
.login-card input[type="password"] {
    background: var(--bg) !important;
    color: var(--text) !important;
    border: 1px solid var(--border) !important;
    font-family: 'Inter', sans-serif;
}
.login-card input::placeholder { color: var(--text-dim) !important; }
.login-card input:focus { border-color: var(--accent) !important; outline: none; }
.login-card .modal-close {
    position: absolute; top: 12px; right: 14px;
    background: var(--bg-warm); border: none; border-radius: 50%;
    width: 32px; height: 32px; display: flex; align-items: center;
    justify-content: center; cursor: pointer; color: var(--text-dim);
    font-size: 1.1rem; transition: all .2s;
}
.login-card .modal-close:hover { background: var(--border); color: var(--text); }

/* Auth tabs (light theme) */
.auth-tabs {
    display: flex; gap: 0; margin-bottom: 1.2rem;
    border-radius: var(--radius-sm); overflow: hidden;
    border: 1px solid var(--border);
}
.auth-tab {
    flex: 1; padding: .65rem; text-align: center; cursor: pointer;
    background: var(--bg); color: var(--text-dim);
    font-weight: 600; font-size: .9rem; border: none;
    transition: all .2s; font-family: 'Inter', sans-serif;
}
.auth-tab.active { background: var(--accent); color: #fff; }
.auth-tab:hover:not(.active) { background: var(--bg-warm); }

/* ── Detail Section ── */
.detail-section {
    background: var(--bg-card);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    padding: 28px;
    margin-bottom: 28px;
}
.detail-section h2 {
    font-size: 22px;
    margin-bottom: 20px;
    font-family: 'Playfair Display', serif;
}

/* Ingredient list with checkmarks */
.ingredient-list { list-style: none; }
.ingredient-list li {
    display: flex; align-items: center; gap: 12px;
    padding: 12px 0; border-bottom: 1px solid var(--border);
    font-size: 15px; cursor: pointer; transition: opacity .2s;
}
.ingredient-list li:last-child { border-bottom: none; }
.ingredient-list li .check-mark {
    width: 24px; height: 24px; border-radius: 50%;
    border: 2px solid var(--border); display: flex;
    align-items: center; justify-content: center;
    flex-shrink: 0; font-size: 13px; color: transparent;
    transition: all .2s;
}
.ingredient-list li:hover .check-mark { border-color: var(--accent); }
.ingredient-list li.checked .check-mark {
    background: var(--green); border-color: var(--green); color: #fff;
}
.ingredient-list li.checked { opacity: 0.5; text-decoration: line-through; }
.ing-note { color: var(--text-dim); font-size: 13px; font-style: italic; }

/* Steps */
.steps-list { display: flex; flex-direction: column; gap: 16px; }
.step-item {
    display: flex; gap: 16px; align-items: flex-start;
}
.step-item .step-number {
    width: 40px; height: 40px; border-radius: 50%;
    background: var(--accent); color: #fff;
    display: flex; align-items: center; justify-content: center;
    font-weight: 700; font-size: 16px; flex-shrink: 0;
}
.step-item .step-content {
    flex: 1; background: var(--bg); border-radius: var(--radius-sm);
    border: 1px solid var(--border); padding: 18px;
}
.step-item .step-content h4 {
    font-size: 15px; font-weight: 600; margin-bottom: 6px;
    font-family: 'Inter', sans-serif; color: var(--text);
}
.step-item .step-content p {
    font-size: 14px; color: var(--text-dim); line-height: 1.6;
}
.step-time {
    display: inline-block; margin-top: 8px;
    font-size: 12px; color: var(--accent); font-weight: 500;
}

/* Tips section */
.tips-section {
    display: flex; gap: 14px; align-items: flex-start;
    background: var(--gold-l) !important;
    border-color: #e8d8b8 !important;
}
.tips-section .tip-icon { font-size: 24px; flex-shrink: 0; }

/* Detail tags */
.detail-tags {
    display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 28px;
}
.detail-tags .tag {
    padding: 5px 14px; background: var(--bg-warm);
    border-radius: 50px; font-size: 13px; color: var(--text-dim);
}

/* User badge (light theme) */
.user-badge {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 3px 12px; border-radius: 20px;
    font-size: .75rem; font-weight: 600;
    background: rgba(212,118,60,.1); color: var(--accent);
}
.user-badge.self { background: rgba(90,138,94,.12); color: var(--green); }

/* Share button (light theme) */
.share-btn {
    display: inline-flex; align-items: center; gap: 4px;
    padding: 8px 16px; border-radius: var(--radius-sm);
    background: var(--bg-warm); color: var(--accent);
    border: 1px solid var(--border); cursor: pointer;
    font-size: .85rem; font-weight: 500; transition: all .2s;
    font-family: 'Inter', sans-serif;
}
.share-btn:hover { background: var(--border); }

/* Share modal (light theme) */
.share-modal {
    position: fixed; inset: 0; z-index: 1100;
    display: flex; align-items: center; justify-content: center;
    background: rgba(0,0,0,.4); backdrop-filter: blur(4px);
}
.share-modal-box {
    background: var(--bg-card); border: 1px solid var(--border);
    border-radius: var(--radius); padding: 28px;
    max-width: 440px; width: 90%; box-shadow: var(--shadow-lg);
}
.share-modal-box h3 { color: var(--text); }
.share-input-row { display: flex; gap: 8px; margin-top: 12px; }
.share-input-row input {
    flex: 1; padding: 10px; border-radius: var(--radius-sm);
    border: 1px solid var(--border); background: var(--bg);
    color: var(--text); font-size: .85rem; font-family: 'Inter', sans-serif;
}

/* Shared recipe banner */
.shared-banner {
    background: var(--bg-warm); border: 1px solid var(--border);
    border-radius: var(--radius-sm); padding: 16px 20px;
    margin-bottom: 24px; display: flex; align-items: center;
    justify-content: space-between; flex-wrap: wrap; gap: 10px;
}
.shared-banner p { color: var(--text-dim); font-size: .9rem; margin: 0; }
.shared-banner strong { color: var(--accent); }
.clone-btn {
    padding: 8px 18px; border-radius: var(--radius-sm);
    background: var(--accent); color: #fff; border: none;
    cursor: pointer; font-weight: 600; font-size: .85rem;
    font-family: 'Inter', sans-serif;
}
.clone-btn:hover { background: var(--accent-h); }

/* Header user info */
.header-user {
    display: flex; align-items: center; gap: 6px;
    color: var(--text-dim); font-size: .85rem;
}
.header-user strong { color: var(--accent); }

@media (max-width: 768px) {
    .login-card { width: 90%; padding: 1.8rem; }
    .step-item { flex-direction: column; gap: 8px; }
    .step-item .step-number { width: 34px; height: 34px; font-size: 14px; }
    .detail-section { padding: 20px; }
    .header-actions { flex-wrap: wrap; justify-content: center; }
}
