diff --git a/docs/app/(home)/components/BuildChatSection/BuildChatSection.module.css b/docs/app/(home)/components/BuildChatSection/BuildChatSection.module.css new file mode 100644 index 000000000..e88468323 --- /dev/null +++ b/docs/app/(home)/components/BuildChatSection/BuildChatSection.module.css @@ -0,0 +1,186 @@ +.section { + width: 100%; + padding-inline: 1.25rem; +} + +.container { + max-width: 75rem; + margin-inline: auto; +} + +.card { + position: relative; + overflow: hidden; + border-radius: 32px; + background: #fff; +} + +.overlay { + position: absolute; + inset: 0; + pointer-events: none; + border: 1px solid rgb(0 0 0 / 10%); + border-radius: 32px; +} + +.content { + display: flex; + flex-direction: column; + gap: 1.5rem; + padding: 1.5rem; +} + +.copyColumn { + display: flex; + flex: 1; + flex-direction: column; + justify-content: space-between; +} + +.copyStack { + display: flex; + flex-direction: column; + gap: 0.75rem; +} + +.title { + max-width: 430px; + font-family: "Inter", sans-serif; + font-size: 32px; + font-weight: 600; + line-height: 1.2; + color: #000; + margin: auto; + text-align: center; +} + +.descriptionWrap { + max-width: 357px; +} + +.description { + font-family: "Inter Display", sans-serif; + font-size: 18px; + line-height: 1.4; + color: rgb(0 0 0 / 40%); +} + +.ctaWrap { + display: flex; + justify-content: center; + padding-top: 1rem; + margin-top: 1.5rem; +} + +.ctaButton { + position: relative; + display: flex; + width: 100%; + max-width: 280px; + align-items: center; + justify-content: center; + gap: 0.625rem; + height: 3rem; + padding-inline: 1.25rem; + border: 0; + border-radius: 999px; + background: #000; + cursor: pointer; + transition: transform 0.2s ease; +} + +.ctaButton:hover { + transform: scale(0.99); + box-shadow: none; +} + +.iconFrame { + position: relative; + display: flex; + height: 1rem; + width: 1rem; + align-items: center; + justify-content: center; +} + +.iconLayer { + position: absolute; + transition: + opacity 0.3s ease, + transform 0.3s ease; +} + +.iconVisible { + opacity: 1; + transform: scale(1); +} + +.iconHidden { + opacity: 0; + transform: scale(0.5); +} + +.ctaLabel { + position: relative; + white-space: nowrap; + font-family: "Inter Display", sans-serif; + font-size: 18px; + font-weight: 500; + line-height: 1.5rem; + color: #fff; +} + +.mediaColumn { + width: 100%; + flex-shrink: 0; +} + +.dashboardImage { + width: 100%; + height: auto; + border-radius: 12px; + object-fit: contain; +} + +@media (min-width: 1024px) { + .section { + padding-inline: 2rem; + } + + .content { + flex-direction: row; + gap: 0; + } + + .copyColumn { + min-height: 0; + padding:16px; + } + + + .title { + max-width: 430px; + font-family: "Inter", sans-serif; + font-size: 36px; + font-weight: 600; + line-height: 1.2; + color: #000; + margin: 4px 0 0 4px; + text-align: left; + } + + .ctaWrap { + justify-content: flex-start; + margin-top: 0; + } + + .ctaButton { + width: auto; + max-width: none; + justify-content: flex-start; + } + + .mediaColumn { + width: 600px; + } +} diff --git a/docs/app/(home)/components/BuildChatSection.tsx b/docs/app/(home)/components/BuildChatSection/BuildChatSection.tsx similarity index 57% rename from docs/app/(home)/components/BuildChatSection.tsx rename to docs/app/(home)/components/BuildChatSection/BuildChatSection.tsx index 80280a6c1..b1987b610 100644 --- a/docs/app/(home)/components/BuildChatSection.tsx +++ b/docs/app/(home)/components/BuildChatSection/BuildChatSection.tsx @@ -3,7 +3,8 @@ import dashboardImg from "@/public/images/home/d67b5e94653944c1d0d4998c6b169c37f98060ad.png"; import Image from "next/image"; import { useEffect, useRef, useState } from "react"; -import { CopyIcon } from "./shared"; +import { CopyIcon } from "../shared/shared"; +import styles from "./BuildChatSection.module.css"; // --------------------------------------------------------------------------- // Constants @@ -16,22 +17,7 @@ const CARD_SHADOW = "0px 8px 16px -4px rgba(22,34,51,0.08)"; // --------------------------------------------------------------------------- function SectionTitle() { - return ( -

- Build an AI chat in minutes -

- ); -} - -function SectionDescription() { - return ( -
-

- This scaffolds a Reference chat interface with a beautiful Component library and a fully - functional OpenUI lang and Renderer. -

-
- ); + return

Build a Generative UI chat in minutes

; } function CtaButton() { @@ -61,19 +47,19 @@ function CtaButton() { }; return ( -
+
@@ -99,7 +85,7 @@ function DashboardIllustration() { AI chat dashboard illustration ); @@ -111,28 +97,27 @@ function DashboardIllustration() { export function BuildChatSection() { return ( -
-
-
+
+
+
{/* Border + shadow overlay */}