/* ==========================================================================
   DeshipOS — Restaurant solution widget
   Built to match the rest of the DeshipOS site (hero / features / how-it-works
   / cta-banner / retail widgets): clean & light, flat soft-green icon tiles,
   solid-green buttons, gradient step badges, green-gradient CTA. Mobile-first.
   Depends on assets/css/base.css for design tokens.
   ========================================================================== */

.deshipos-restaurant {
	--dres-accent:   var(--dew-brand, #16A34A);
	--dres-accent-2: var(--dew-brand-strong, #15803D);
	--dres-accent-3: var(--dew-accent, #22C55E);
	--dres-soft:     var(--dew-brand-soft, rgba(22, 163, 74, .12));
	--dres-ink:      var(--dew-ink, #0F172A);
	--dres-text:     var(--dew-text, #1E293B);
	--dres-muted:    var(--dew-muted, #475569);
	--dres-border:   var(--dew-divider, #E2E8F0);
	--dres-bg:       var(--dew-bg, #FFFFFF);
	--dres-soft-bg:  #FAFBFC;

	box-sizing: border-box;
	width: 100%;
	padding: 56px 20px;
	color: var(--dres-text);
	background: var(--dres-bg);
}
.deshipos-restaurant *,
.deshipos-restaurant *::before,
.deshipos-restaurant *::after { box-sizing: border-box; }

.deshipos-restaurant__inner {
	max-width: 1200px;
	margin-left: auto;
	margin-right: auto;
}

/* Shared eyebrow — soft-green pill (matches How It Works) */
.deshipos-restaurant__eyebrow {
	display: inline-block;
	font-size: 13px;
	font-weight: 700;
	letter-spacing: .08em;
	text-transform: uppercase;
	color: var(--dres-accent-2);
	background: var(--dres-soft);
	padding: 6px 14px;
	border-radius: 999px;
	margin-bottom: 18px;
}

/* Block heads */
.deshipos-restaurant__block { margin-top: 72px; }
.deshipos-restaurant__block-head {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 12px;
	max-width: 640px;
	margin: 0 auto 40px;
}
.deshipos-restaurant__block-head .deshipos-restaurant__eyebrow { margin-bottom: 0; }
.deshipos-restaurant__block-title {
	margin: 0;
	font-size: clamp(1.625rem, 3.5vw, 2.25rem);
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: var(--dew-tracking-tight);
	color: var(--dres-ink);
}
.deshipos-restaurant__block-sub {
	margin: 0;
	font-size: 1.0625rem;
	line-height: 1.65;
	color: var(--dres-muted);
}

/* ==========================================================================
   Hero
   ========================================================================== */
.deshipos-restaurant__hero {
	display: flex;
	flex-direction: column;
	gap: 40px;
	align-items: flex-start;
}
.deshipos-restaurant__hero-text {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	min-width: 0;
}
.deshipos-restaurant__heading {
	margin: 0 0 18px;
	font-size: clamp(2rem, 5.2vw, 3.25rem);
	font-weight: 800;
	line-height: 1.1;
	letter-spacing: var(--dew-tracking-tight);
	color: var(--dres-ink);
}
.deshipos-restaurant__lead {
	margin: 0 0 28px;
	font-size: 1.0625rem;
	line-height: 1.6;
	color: var(--dres-muted);
	max-width: 560px;
}

/* Buttons — match Hero widget (radius 8px, solid green / bordered) */
.deshipos-restaurant__cta-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.deshipos-restaurant__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 13px 24px;
	border-radius: 8px;
	font-size: .9375rem;
	font-weight: 600;
	text-decoration: none;
	border: 1.5px solid transparent;
	cursor: pointer;
	white-space: nowrap;
	transition: transform var(--dew-dur-fast) var(--dew-ease-out),
	            background var(--dew-dur-fast) var(--dew-ease-out),
	            color var(--dew-dur-fast) var(--dew-ease-out),
	            box-shadow var(--dew-dur-fast) var(--dew-ease-out),
	            border-color var(--dew-dur-fast) var(--dew-ease-out);
}
.deshipos-restaurant__btn--primary {
	background: var(--dres-accent);
	border-color: var(--dres-accent);
	color: #fff;
	box-shadow: var(--dew-shadow-brand-sm);
}
.deshipos-restaurant__btn--primary:hover {
	background: var(--dres-accent-2);
	border-color: var(--dres-accent-2);
	transform: translateY(-1px);
	box-shadow: var(--dew-shadow-brand-md);
}
.deshipos-restaurant__btn--primary:hover svg { transform: translateX(3px); }
.deshipos-restaurant__btn svg { transition: transform var(--dew-dur-base) var(--dew-ease-out); }
.deshipos-restaurant__btn--ghost {
	background: transparent;
	border-color: var(--dres-border);
	color: var(--dres-ink);
}
.deshipos-restaurant__btn--ghost:hover { border-color: var(--dres-ink); transform: translateY(-1px); }

/* Hero media */
.deshipos-restaurant__hero-media {
	position: relative;
	width: 100%;
	min-width: 0;
}
.deshipos-restaurant__media-img {
	display: block;
	width: 100%;
	height: auto;
	box-shadow: var(--dew-shadow-lg);
	border-radius: 10px !important;
}
/* Floating badge — clean white card (matches the site's flat card aesthetic) */
.deshipos-restaurant__badge {
	position: absolute;
	left: 16px;
	bottom: 16px;
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 16px;
	background: var(--dres-bg);
	border: 1px solid var(--dres-border);
	border-radius: 14px;
	box-shadow: var(--dew-shadow-lg);
	max-width: 240px;
}
.deshipos-restaurant__badge-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 42px; height: 42px;
	flex: none;
	border-radius: 11px;
	background: var(--dres-soft);
	color: var(--dres-accent);
}
.deshipos-restaurant__badge-meta { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.deshipos-restaurant__badge-value { font-size: 1.25rem; font-weight: 800; color: var(--dres-ink); line-height: 1.1; }
.deshipos-restaurant__badge-label { font-size: .75rem; line-height: 1.3; color: var(--dres-muted); }

/* ==========================================================================
   Capabilities — single-column timeline, icon dot ON the line
   The green icon dot sits on the spine, vertically centred to its card; the
   card (title + text) sits to the right. The connecting line is drawn per item
   (dot-centre to next dot-centre) so it stays joined no matter the card height.
   ========================================================================== */
.deshipos-restaurant__timeline {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: 24px;
}
.deshipos-restaurant__tl-item {
	position: relative;
	display: grid;
	grid-template-columns: 56px 1fr;
	column-gap: 20px;
	align-items: center;   /* dot sits at the vertical middle of the card */
}
/* Connector line: from this dot's centre down to the next dot's centre.
   height = item height (100%) + the flex gap (24px), so it meets the next dot.
   Skipped after the last item so the line never overshoots the bottom. */
.deshipos-restaurant__tl-item:not(:last-child)::before {
	content: "";
	position: absolute;
	left: 27px;            /* centre of the 56px dot column (x = 28) */
	top: 50%;
	height: calc(100% + 24px);
	width: 2px;
	background: var(--dres-border);
	z-index: 0;
}
.deshipos-restaurant__tl-dot {
	grid-column: 1;
	grid-row: 1;
	position: relative;
	z-index: 1;            /* above the connector line */
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 56px;
	height: 56px;
	flex: none;
	border-radius: 999px;
	background: linear-gradient(135deg, var(--dres-accent) 0%, var(--dres-accent-2) 100%);
	color: #fff;
	font-size: 1.25rem;
	font-weight: 800;
	line-height: 1;
	box-shadow: var(--dew-shadow-md);
	border: 4px solid var(--dres-bg); /* clean break where the line passes behind */
}
.deshipos-restaurant__tl-dot i { font-size: 22px; line-height: 1; color: #fff; }
.deshipos-restaurant__tl-dot svg { width: 24px; height: 24px; fill: #fff; }
.deshipos-restaurant__tl-dot svg path,
.deshipos-restaurant__tl-dot svg g,
.deshipos-restaurant__tl-dot svg circle,
.deshipos-restaurant__tl-dot svg rect,
.deshipos-restaurant__tl-dot svg polygon { fill: #fff; }
.deshipos-restaurant__tl-card {
	grid-column: 2;
	grid-row: 1;
	min-width: 0;
	background: var(--dres-bg);
	border: 1px solid var(--dres-border);
	border-radius: 14px;
	padding: 18px 20px;
	transition: transform var(--dew-dur-base) var(--dew-ease-out),
	            box-shadow var(--dew-dur-base) var(--dew-ease-out),
	            border-color var(--dew-dur-base) var(--dew-ease-out);
}
.deshipos-restaurant__tl-card:hover {
	transform: translateY(-2px);
	box-shadow: var(--dew-shadow-lg);
	border-color: var(--dres-accent);
}
.deshipos-restaurant__tl-title {
	margin: 0 0 5px;
	font-size: 1.0625rem;
	font-weight: 700;
	line-height: 1.35;
	color: var(--dres-ink);
	letter-spacing: var(--dew-tracking-snug);
}
.deshipos-restaurant__tl-desc {
	margin: 0;
	font-size: .9375rem;
	line-height: 1.6;
	color: var(--dres-muted);
}

/* ==========================================================================
   How it works — match How It Works steps (gradient badges + dashed connector)
   ========================================================================== */
.deshipos-restaurant__steps {
	list-style: none;
	margin: 0;
	padding: 0;
	display: grid;
	grid-template-columns: 1fr;
	gap: 32px;
}
.deshipos-restaurant__step {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 12px;
}
.deshipos-restaurant__step-num {
	position: relative;
	z-index: 1;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 60px;
	height: 60px;
	border-radius: 999px;
	background: linear-gradient(135deg, var(--dres-accent) 0%, var(--dres-accent-2) 100%);
	color: #fff;
	font-size: 1.375rem;
	font-weight: 800;
	line-height: 1;
	box-shadow: var(--dew-shadow-md);
}
.deshipos-restaurant__step-num i { font-size: 1.5rem; color: #fff; }
.deshipos-restaurant__step-num svg { width: 26px; height: 26px; fill: #fff; }
.deshipos-restaurant__step-num svg path,
.deshipos-restaurant__step-num svg g,
.deshipos-restaurant__step-num svg circle,
.deshipos-restaurant__step-num svg rect,
.deshipos-restaurant__step-num svg polygon { fill: #fff; }
.deshipos-restaurant__step-title {
	margin: 0;
	font-size: 1.125rem;
	font-weight: 700;
	line-height: 1.3;
	letter-spacing: var(--dew-tracking-snug);
	color: var(--dres-ink);
}
.deshipos-restaurant__step-desc {
	margin: 0;
	font-size: .9375rem;
	line-height: 1.6;
	color: var(--dres-muted);
}

/* ==========================================================================
   CTA banner — match CTA Banner widget (green gradient pill, pill buttons)
   ========================================================================== */
.deshipos-restaurant__cta {
	margin-top: 72px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 32px;
	padding: 40px;
	border-radius: 16px;
	background: linear-gradient(115deg, #1BA950 0%, #17A24A 55%, #138C43 100%);
	color: #fff;
}
.deshipos-restaurant__cta-heading {
	margin: 0 0 10px;
	font-size: clamp(1.375rem, 1.1rem + 1.2vw, 2rem);
	font-weight: 800;
	line-height: 1.2;
	letter-spacing: var(--dew-tracking-tight);
	color: #fff;
}
.deshipos-restaurant__cta-text {
	margin: 0;
	font-size: clamp(.9375rem, .85rem + .25vw, 1.0625rem);
	line-height: 1.55;
	color: rgba(255, 255, 255, .9);
	max-width: 560px;
}
.deshipos-restaurant__btn--light {
	flex: none;
	min-height: 46px;
	border-radius: 999px;
	padding: 12px 26px;
	font-weight: 700;
	color: var(--dres-accent-2);
	background: #fff;
	box-shadow: 0 6px 18px -6px rgba(0, 0, 0, .35);
}
.deshipos-restaurant__btn--light:hover { transform: translateY(-1px); box-shadow: 0 10px 24px -8px rgba(0, 0, 0, .4); }
.deshipos-restaurant__btn--light:hover svg { transform: translateX(3px); }

/* ==========================================================================
   Scroll reveal
   ========================================================================== */
.deshipos-restaurant.js-reveal [data-reveal] {
	opacity: 0;
	transform: translateY(20px);
	transition: opacity .6s var(--dew-ease-out), transform .6s var(--dew-ease-out);
	will-change: opacity, transform;
}
.deshipos-restaurant.js-reveal [data-reveal].is-in { opacity: 1; transform: none; }

/* ==========================================================================
   Responsive — mirror the site's breakpoints (600 / 960)
   ========================================================================== */
@media (min-width: 600px) {
	.deshipos-restaurant { padding: 64px 32px; }
	.deshipos-restaurant__steps { grid-template-columns: repeat(2, 1fr); }
	/* Keep the single-column timeline a comfortable reading width, centred */
	.deshipos-restaurant__timeline { max-width: 760px; margin: 0 auto; }
}

@media (min-width: 960px) {
	.deshipos-restaurant { padding: 88px 40px; }
	.deshipos-restaurant__block { margin-top: 96px; }
	.deshipos-restaurant__cta { margin-top: 96px; }

	/* Hero: two columns (text left, image right) */
	.deshipos-restaurant__hero {
		flex-direction: row;
		align-items: center;
		gap: 64px;
	}
	.deshipos-restaurant__hero--rev { flex-direction: row-reverse; }
	.deshipos-restaurant__hero-text,
	.deshipos-restaurant__hero-media { flex: 1 1 0; }

	/* Capabilities timeline: cards zig-zag left/right of a centred line, with
	   the icon dot on the line at each card's vertical middle. Wider than the
	   single-column reading width so both sides have room. */
	.deshipos-restaurant__timeline { max-width: 1080px; }
	.deshipos-restaurant__tl-item {
		grid-template-columns: 1fr 56px 1fr;
		column-gap: 0;
	}
	/* Connector now runs down the centre instead of the left */
	.deshipos-restaurant__tl-item:not(:last-child)::before { left: calc(50% - 1px); }
	.deshipos-restaurant__tl-dot { grid-column: 2; }
	.deshipos-restaurant__tl-item:nth-child(odd) .deshipos-restaurant__tl-card {
		grid-column: 1;
		text-align: right;
		margin-right: 30px;
	}
	.deshipos-restaurant__tl-item:nth-child(even) .deshipos-restaurant__tl-card {
		grid-column: 3;
		text-align: left;
		margin-left: 30px;
	}

	/* Steps: 4 across with a dashed connector behind the badges */
	.deshipos-restaurant__steps { grid-template-columns: repeat(4, 1fr); }
	.deshipos-restaurant__steps--connect .deshipos-restaurant__step:not(:last-child)::before {
		content: "";
		position: absolute;
		top: 29px;
		left: 50%;
		width: calc(100% + 32px);
		height: 0;
		border-top: 2px dashed var(--dres-border);
		z-index: 0;
	}
}

@media (max-width: 600px) {
	.deshipos-restaurant__cta { flex-direction: column; align-items: flex-start; gap: 22px; text-align: left; }
	.deshipos-restaurant__btn--light { width: 100%; }
	.deshipos-restaurant__cta-row .deshipos-restaurant__btn { flex: 1; }
}

@media (prefers-reduced-motion: reduce) {
	.deshipos-restaurant *,
	.deshipos-restaurant *::before,
	.deshipos-restaurant *::after { transition-duration: .01ms !important; }
	.deshipos-restaurant.js-reveal [data-reveal] { opacity: 1 !important; transform: none !important; transition: none !important; }
	.deshipos-restaurant__btn:hover, .deshipos-restaurant__card:hover { transform: none !important; }
}
