426 lines
7.6 KiB
CSS
426 lines
7.6 KiB
CSS
/* ===== CSS Variables ===== */
|
|
:root {
|
|
--accent-color: rgb(38, 186, 216);
|
|
--accent-hover: rgb(25, 150, 180);
|
|
--accent-light: rgb(80, 205, 235);
|
|
--background-gradient: linear-gradient(
|
|
135deg,
|
|
var(--accent-hover) 0%,
|
|
var(--accent-color) 100%
|
|
);
|
|
--glass-bg: rgba(255, 255, 255, 0.95);
|
|
--glass-border: rgba(255, 255, 255, 0.2);
|
|
--text-primary: #1f2937;
|
|
--text-secondary: #6b7280;
|
|
--text-light: #9ca3af;
|
|
--shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
|
|
--shadow-md:
|
|
0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
|
|
--shadow-lg:
|
|
0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
|
|
--shadow-xl:
|
|
0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
|
|
--border-radius-sm: 8px;
|
|
--border-radius-md: 12px;
|
|
--border-radius-lg: 16px;
|
|
--border-radius-xl: 24px;
|
|
--transition-fast: 0.15s ease;
|
|
--transition-normal: 0.3s ease;
|
|
--transition-slow: 0.5s ease;
|
|
}
|
|
|
|
/* ===== Font Face Declarations ===== */
|
|
@font-face {
|
|
font-family: "Intelo";
|
|
src: url("../fonts/intelo-regular.woff2") format("woff2");
|
|
font-weight: 400;
|
|
font-style: normal;
|
|
font-display: swap;
|
|
}
|
|
|
|
@font-face {
|
|
font-family: "Intelo";
|
|
src: url("../fonts/intelo-light.woff2") format("woff2");
|
|
font-weight: 300;
|
|
font-style: normal;
|
|
font-display: swap;
|
|
}
|
|
|
|
@font-face {
|
|
font-family: "Intelo";
|
|
src: url("../fonts/intelo-bold.woff2") format("woff2");
|
|
font-weight: 700;
|
|
font-style: normal;
|
|
font-display: swap;
|
|
}
|
|
|
|
/* ===== Reset & Base Styles ===== */
|
|
* {
|
|
margin: 0;
|
|
padding: 0;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
body {
|
|
font-family:
|
|
"Intelo",
|
|
-apple-system,
|
|
BlinkMacSystemFont,
|
|
"Segoe UI",
|
|
Roboto,
|
|
"Helvetica Neue",
|
|
Arial,
|
|
sans-serif;
|
|
background: var(--background-gradient);
|
|
min-height: 100vh;
|
|
display: flex;
|
|
justify-content: center;
|
|
align-items: center;
|
|
padding: 20px;
|
|
color: var(--text-primary);
|
|
line-height: 1.6;
|
|
}
|
|
|
|
/* ===== App Container ===== */
|
|
.app-container {
|
|
width: 100%;
|
|
max-width: 900px;
|
|
height: 90vh;
|
|
max-height: 800px;
|
|
background: var(--glass-bg);
|
|
backdrop-filter: blur(20px);
|
|
border-radius: var(--border-radius-xl);
|
|
box-shadow: var(--shadow-xl);
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow: hidden;
|
|
border: 1px solid var(--glass-border);
|
|
animation: fadeInUp 0.6s ease-out;
|
|
}
|
|
|
|
@keyframes fadeInUp {
|
|
from {
|
|
opacity: 0;
|
|
transform: translateY(30px);
|
|
}
|
|
|
|
to {
|
|
opacity: 1;
|
|
transform: translateY(0);
|
|
}
|
|
}
|
|
|
|
/* ===== Header ===== */
|
|
.chat-header {
|
|
background: linear-gradient(
|
|
135deg,
|
|
var(--accent-hover) 0%,
|
|
var(--accent-color) 100%
|
|
);
|
|
padding: 20px 24px;
|
|
display: flex;
|
|
justify-content: center;
|
|
align-items: center;
|
|
box-shadow: var(--shadow-md);
|
|
z-index: 10;
|
|
}
|
|
|
|
.header-content img {
|
|
width: 200px;
|
|
}
|
|
|
|
/* ===== Main Content ===== */
|
|
.chat-main {
|
|
flex: 1;
|
|
display: flex;
|
|
flex-direction: column;
|
|
overflow-y: auto;
|
|
background: linear-gradient(180deg, #f8fafc 0%, #f1f5f9 100%);
|
|
scroll-behavior: smooth;
|
|
}
|
|
|
|
.chat-main::-webkit-scrollbar {
|
|
width: 6px;
|
|
}
|
|
|
|
.chat-main::-webkit-scrollbar-track {
|
|
background: transparent;
|
|
}
|
|
|
|
.chat-main::-webkit-scrollbar-thumb {
|
|
background: var(--text-light);
|
|
border-radius: 3px;
|
|
}
|
|
|
|
.chat-main::-webkit-scrollbar-thumb:hover {
|
|
background: var(--text-secondary);
|
|
}
|
|
|
|
/* ===== Messages Container ===== */
|
|
.messages-container {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 16px;
|
|
padding: 24px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
/* ===== Message Styles ===== */
|
|
.message {
|
|
max-width: 75%;
|
|
padding: 14px 20px 6px 20px;
|
|
border-radius: var(--border-radius-lg);
|
|
font-size: 0.95rem;
|
|
line-height: 1.6;
|
|
animation: messageSlide 0.3s ease-out;
|
|
word-wrap: break-word;
|
|
}
|
|
|
|
@keyframes messageSlide {
|
|
from {
|
|
opacity: 0;
|
|
transform: translateY(10px);
|
|
}
|
|
|
|
to {
|
|
opacity: 1;
|
|
transform: translateY(0);
|
|
}
|
|
}
|
|
|
|
.sent {
|
|
align-self: flex-end;
|
|
background: linear-gradient(
|
|
135deg,
|
|
var(--accent-hover) 0%,
|
|
var(--accent-color) 100%
|
|
);
|
|
color: white;
|
|
border-bottom-right-radius: 4px;
|
|
box-shadow: var(--shadow-md);
|
|
}
|
|
|
|
.sent a {
|
|
color: white;
|
|
text-decoration: underline;
|
|
}
|
|
|
|
.received {
|
|
align-self: flex-start;
|
|
background: white;
|
|
color: var(--text-primary);
|
|
border-bottom-left-radius: 4px;
|
|
box-shadow: var(--shadow-sm);
|
|
border: 1px solid rgba(0, 0, 0, 0.05);
|
|
}
|
|
|
|
.received a {
|
|
color: var(--accent-color);
|
|
text-decoration: none;
|
|
}
|
|
|
|
.received a:hover {
|
|
text-decoration: underline;
|
|
}
|
|
|
|
/* ===== Message Content Lists ===== */
|
|
.message ul,
|
|
.message ol {
|
|
margin: 0 0 8px 0;
|
|
padding-left: 20px;
|
|
}
|
|
|
|
.message p {
|
|
margin: 0 0 8px 0;
|
|
}
|
|
|
|
.message ul {
|
|
list-style-type: disc;
|
|
}
|
|
|
|
.message ol {
|
|
list-style-type: decimal;
|
|
}
|
|
|
|
.message li {
|
|
margin: 4px 0;
|
|
line-height: 1.6;
|
|
}
|
|
|
|
.message li::marker {
|
|
color: var(--accent-color);
|
|
}
|
|
|
|
/* Nested lists */
|
|
.message ul ul,
|
|
.message ol ol,
|
|
.message ul ol,
|
|
.message ol ul {
|
|
margin: 4px 0;
|
|
}
|
|
|
|
/* ===== Footer ===== */
|
|
.chat-footer {
|
|
background: white;
|
|
padding: 20px 24px;
|
|
border-top: 1px solid rgba(0, 0, 0, 0.05);
|
|
box-shadow: 0 -4px 6px -1px rgba(0, 0, 0, 0.05);
|
|
}
|
|
|
|
.input-wrapper {
|
|
display: flex;
|
|
gap: 12px;
|
|
align-items: flex-end;
|
|
background: var(--background-gradient);
|
|
padding: 6px;
|
|
border-radius: var(--border-radius-lg);
|
|
box-shadow: var(--shadow-md);
|
|
transition: box-shadow var(--transition-normal);
|
|
}
|
|
|
|
.input-wrapper:focus-within {
|
|
box-shadow: var(--shadow-lg);
|
|
}
|
|
|
|
.message-input {
|
|
flex: 1;
|
|
background: white;
|
|
border: none;
|
|
border-radius: var(--border-radius-md);
|
|
padding: 14px 16px;
|
|
font-size: 1rem;
|
|
font-family: inherit;
|
|
color: var(--text-primary);
|
|
resize: none;
|
|
outline: none;
|
|
min-height: 50px;
|
|
max-height: 150px;
|
|
field-sizing: content;
|
|
transition: box-shadow var(--transition-fast);
|
|
}
|
|
|
|
.message-input::placeholder {
|
|
color: var(--text-light);
|
|
}
|
|
|
|
.message-input:focus {
|
|
box-shadow: 0 0 0 3px rgba(38, 186, 216, 0.2);
|
|
}
|
|
|
|
.message-input:disabled {
|
|
opacity: 0.6;
|
|
cursor: not-allowed;
|
|
background: #f3f4f6;
|
|
}
|
|
|
|
.send-button {
|
|
width: 50px;
|
|
height: 50px;
|
|
background: linear-gradient(
|
|
135deg,
|
|
var(--accent-hover) 0%,
|
|
var(--accent-color) 100%
|
|
);
|
|
border: none;
|
|
border-radius: var(--border-radius-md);
|
|
color: white;
|
|
cursor: pointer;
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
transition: all var(--transition-normal);
|
|
box-shadow: var(--shadow-md);
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.send-button:hover {
|
|
transform: scale(1.05);
|
|
box-shadow: var(--shadow-lg);
|
|
}
|
|
|
|
.send-button:active {
|
|
transform: scale(0.95);
|
|
}
|
|
|
|
.send-button:disabled {
|
|
opacity: 0.5;
|
|
cursor: not-allowed;
|
|
transform: none;
|
|
}
|
|
|
|
.footer-hint {
|
|
text-align: center;
|
|
font-size: 0.75rem;
|
|
color: var(--text-light);
|
|
margin-top: 12px;
|
|
}
|
|
|
|
/* ===== Responsive Design ===== */
|
|
@media (max-width: 768px) {
|
|
body {
|
|
padding: 10px;
|
|
}
|
|
|
|
.app-container {
|
|
height: 95vh;
|
|
max-height: none;
|
|
border-radius: var(--border-radius-lg);
|
|
}
|
|
|
|
.chat-header {
|
|
padding: 16px 20px;
|
|
}
|
|
|
|
.chat-main {
|
|
padding: 0;
|
|
}
|
|
|
|
.messages-container {
|
|
padding: 16px;
|
|
gap: 12px;
|
|
}
|
|
|
|
.message {
|
|
max-width: 85%;
|
|
padding: 12px 14px;
|
|
font-size: 0.9rem;
|
|
}
|
|
|
|
.chat-footer {
|
|
padding: 16px 20px;
|
|
}
|
|
|
|
.message-input {
|
|
padding: 12px 14px;
|
|
font-size: 0.95rem;
|
|
}
|
|
|
|
.send-button {
|
|
width: 46px;
|
|
height: 46px;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.message {
|
|
max-width: 90%;
|
|
}
|
|
}
|
|
|
|
/* ===== Loading Animation ===== */
|
|
@keyframes shimmer {
|
|
0% {
|
|
background-position: -200% 0;
|
|
}
|
|
|
|
100% {
|
|
background-position: 200% 0;
|
|
}
|
|
}
|
|
|
|
.loading-message {
|
|
background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
|
|
background-size: 200% 100%;
|
|
animation: shimmer 1.5s infinite;
|
|
}
|