@import url("https://fonts.googleapis.com/css2?family=Pridi:wght@400;500;600&display=swap");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Pridi', sans-serif;
}

:root {
  /* Light mode colors */
  --text-color: #222;
  --subheading-color: #a9a9a9;
  --placeholder-color: #6c6c6c;
  --primary-color: #fff;
  --secondary-color: #e9eef6;
  --secondary-hover-color: #dbe1ea;
}

body {
  background: var(--primary-color);
}

.header,
.chat-list .message,
.typing-form {
  margin: 0 auto;
  max-width: 980px;
}

.header {
  margin-top: 2.5vh;
  padding: 1rem;
  overflow-x: hidden;
}

body.hide-header .header {
  margin: 0;
  display: none;
}

.header :where(.title, .subtitle) {
  color: var(--text-color);
  font-weight: 400;
  line-height: 3.2rem;
}

.header .title {
  width: fit-content;
  font-size: 2.8rem;
  font-weight: 600;
  background-clip: text;
  background: linear-gradient(to right, #ee6e00, #a32000);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.header .subtitle {
  font-size: 2.1rem;
  font-weight: 400;
  color: var(--subheading-color);
}

.suggestion-list {
  width: 100%;
  list-style: none;
  display: flex;
  gap: 1.25rem;
  margin-top: 9.5vh;
  overflow: hidden;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scrollbar-width: none;
}

.suggestion-list .suggestion {
  cursor: pointer;
  padding: 1.25rem;
  width: 222px;
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  border-radius: 0.75rem;
  justify-content: space-between;
  background: var(--secondary-color);
  transition: 0.2s ease;
}

.suggestion-list .suggestion:hover {
  background: var(--secondary-hover-color);
}

.suggestion-list .suggestion :where(.text, .icon) {
  font-weight: 400;
  color: var(--text-color);
}

.suggestion-list .suggestion .icon {
  width: 42px;
  height: 42px;
  display: flex;
  font-size: 1.3rem;
  margin-top: 2.5rem;
  align-self: flex-end;
  align-items: center;
  border-radius: 50%;
  justify-content: center;
  color: var(--text-color);
  background: var(--primary-color);
}

.chat-list {
  padding: 2rem 1rem 12rem;
  /*max-height: 100vh;*/
  /*overflow-y: auto;*/
  scrollbar-color: #999 transparent;
}

.chat-list .message.incoming {
  margin-top: 1.5rem;
}

.chat-list .message .message-content {
  display: flex;
  gap: 0.8rem;
  width: 100%;
  align-items: center;
}

.chat-list .message .text {
  color: var(--text-color);
  white-space: pre-wrap;
}

.chat-list .message.error .text {
  color: #e55865;
}

.chat-list .message.loading .text {
  display: none;
}

.chat-list .message .avatar {
  width: 40px;
  height: 40px;
  object-fit: cover;
  border-radius: 50%;
  align-self: flex-start;
}

.chat-list .message.loading .avatar {
  animation: rotate 3s linear infinite;
}

@keyframes rotate {
  100% {
    transform: rotate(360deg);
  }
}

.chat-list .message .icon {
  color: var(--text-color);
  cursor: pointer;
  height: 35px;
  width: 35px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  font-size: 1.25rem;
  margin-left: 3.5rem;
  visibility: hidden;
}

.chat-list .message .icon.hide {
  visibility: hidden;
}

.chat-list .message:not(.loading, .error):hover .icon:not(.hide) {
  visibility: visible;
}

.chat-list .message .icon:hover {
  background: var(--secondary-hover-color);
}

/* ---------- TYPING INDICATOR ---------- */
.chat-list .message .typing-indicator {
  display: none;
  gap: 4px;
  padding: 4px 2px;
  margin-top: 2px;
}

.chat-list .message.loading .typing-indicator {
  display: flex;
}

.chat-list .message .typing-indicator .dot {
  width: 8px;
  height: 8px;
  /* background: var(--subheading-color); */
  background: #d74702;
  border-radius: 50%;
  animation: typing 1s infinite ease-in-out;
}

.chat-list .message .typing-indicator .dot:nth-child(1) {
  animation-delay: 0.2s;
}

.chat-list .message .typing-indicator .dot:nth-child(2) {
  animation-delay: 0.3s;
}

.chat-list .message .typing-indicator .dot:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes typing {
  0%, 100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-10px);
  }
}

.typing-area {
  position: fixed;
  width: 100%;
  left: 0;
  bottom: 0;
  padding: 1rem;
  background: var(--primary-color);
}

.typing-area :where(.typing-form, .action-buttons) {
  display: flex;
  gap: 0.75rem;
}

.typing-form .input-wrapper {
  width: 100%;
  height: 56px;
  display: flex;
  position: relative;
}

.typing-form .typing-input {
  height: 100%;
  width: 100%;
  border: none;
  outline: none;
  resize: none;
  font-size: 1rem;
  color: var(--text-color);
  padding: 1.1rem 4rem 1.1rem 1.5rem;
  border-radius: 100px;
  background: var(--secondary-color);
}

.typing-form .typing-input:focus {
  background: var(--secondary-hover-color);
}

.typing-form .typing-input::placeholder {
  color: var(--placeholder-color);
}

.typing-area .icon {
  width: 56px;
  height: 56px;
  flex-shrink: 0;
  cursor: pointer;
  border-radius: 50%;
  display: flex;
  font-size: 1.4rem;
  color: var(--text-color);
  align-items: center;
  justify-content: center;
  background: var(--secondary-color);
  transition: 0.2s ease;
}

.typing-area .icon:hover {
  background: var(--secondary-hover-color);
}

.typing-form #send-message-button {
  position: absolute;
  right: 0;
  outline: none;
  border: none;
  transform: scale(0);
  background: transparent;
  transition: transform 0.2s ease;
}

.typing-form .typing-input:valid ~ #send-message-button {
  transform: scale(1);
}

.typing-area .disclaimer-text {
  text-align: center;
  font-size: 0.85rem;
  margin-top: 1rem;
  color: var(--placeholder-color);
}

/* New styles for the hyperlink inside disclaimer text */
.typing-area .disclaimer-text a {
    color: #1E90FF;  /* Light blue color */
    text-decoration: none;  /* Removes underline */
    transition: color 0.3s ease;  /* Smooth color transition effect */
}

/* Hover effect for the hyperlink */
.typing-area .disclaimer-text a:hover {
    color: #93b3d4;  /* Orange-Red color */
}

/* Responsive media query code for small screen */
@media (max-width: 768px) {
/*   .card-container{*/
/*    position: relative;*/
/*    height: 280px !important;*/
/*}*/
  /* Existing styles remain the same */
  .header :is(.title, .subtitle) {
    font-size: 2rem;
    line-height: 2rem;
  }

  .header .subtitle {
    font-size: 1.4rem;
  }

  /* Add these new styles for the suggestion list */
  .suggestion-list {
    flex-wrap: wrap; /* Allow items to wrap to next line */
    justify-content: center; /* Center items horizontally */
    gap: 1rem; /* Reduce gap between items */
  }

  .suggestion-list .suggestion {
    width: calc(50% - 0.5rem); /* Make each suggestion take up roughly half the width */
    min-width: 160px; /* Set a minimum width */
    padding: 1rem; /* Reduce padding */
  }

  .suggestion-list .suggestion .text {
    font-size: 0.9rem; /* Make text slightly smaller */
  }

  .suggestion-list .suggestion .icon {
    width: 35px; /* Make icon slightly smaller */
    height: 35px;
    font-size: 1.1rem;
    margin-top: 1.5rem; /* Reduce top margin */
  }
}

/* ─── Tarot Cards Alignment ────────────────── */
.chat-list .message.incoming .text {
  /* mobile: grid → first card full-width, next two side-by-side */
  display: flex; 
  flex-wrap: wrap; 
  justify-content: flex-start;
  gap: 0.25rem 0.5rem;
}

/* tidy up the description text */
.chat-list .message.incoming .text span {
  display: block; 
  margin-bottom: 0.5rem;
}
.message.incoming.loading .message-content p.text{
  display: none !important;
}

/* images responsive & centred */
.chat-list .message.incoming .text img {
  display: block;
  /* margin: 0.75rem auto; */
  max-width: 100%;
  height: auto;
  border-radius: 8px !important;
  overflow: hidden;
  width: 128px; /* Set fixed width */
  max-width: 128px; /* Set maximum width */
}


/* MOBILE LAYOUT
  [1] [2]
  [3] [4]
    [5]  */
@media (max-width: 767px) {
  .chat-list .message.incoming .text {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem; /* Reduced from 1rem to 0.5rem */
    justify-content: center;
    --card-w: clamp(140px, calc(50% - 0.5rem), 200px);
  }

  .chat-list .message.incoming .text > img {
    flex: 0 0 var(--card-w);
    width: var(--card-w);
    max-width: var(--card-w);
    height: auto;
    border-radius: 8px !important;
    overflow: hidden;
    margin-bottom: 0.25rem; /* Add small margin at bottom of images */
  }

  /* Last image centers if it's alone in its row */
  .chat-list .message.incoming .text > img:last-child:nth-child(odd) {
    margin: 0 auto;
  }

  /* Add spacing before text content */
  .chat-list .message.incoming .text span {
    margin-top: 0.25rem; /* Add small margin before text */
  }
}





/*CARD CODE IMPLEMENT*/
.w-full{
    width: 100%;
}
.card-container-cover{
    margin-top: 30px;
    width: 600px;
    max-width: 100%;
    padding: 0px 35px;
}
.card-container{
    position: relative;
    height: 400px;
}




.card-rows{
    display: flex;
    justify-content: center;
    transform: translateX(35px);
}
.card{
    /* width: 100px;
    height: 167px; */
    display: flex;
    justify-content: flex-start;
    align-items: flex-start;
    border-radius: 10px;
    margin-left: -70px;
    border-radius: 10px;
    cursor: pointer;
    visibility: visible;
    opacity:1;
    transition:0.3s ease-in-out;
}
.card img{
    border-radius: 10px;
}
.card:is(:hover,.active){
    transition: 0.3s ease-in-out;
}
.card.active img{
    box-shadow: 1px 0px 10px 0px rgb(255, 255, 255), 0px 0px 0px 0px rgb(255, 255, 255);
    margin-top: -25px;
}

.hoverside{
    visibility: hidden;
}
.hoverActive .card:hover .hoverside{
    visibility: visible;
}
.hoverActive .card:hover .nothover{
    visibility: hidden;
}
.card.active .hoverside{
    visibility: visible;
}
.card.active .nothover{
    visibility: hidden;
}

.card-hide{
    visibility: hidden;
    opacity:0;
}


/* CSS */

/* Default styles for mobile (smaller screens) */
.modern-btn {
  padding: 10px 20px;
  background: #909191;  /* Solid black background */
  border: none;
  border-radius: 8px;
  color: white;
  font-size: 18px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
  width: 100px;
  margin: 10px auto;
  display: block;
}

.modern-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
  background: #595959;  /* Slightly lighter black on hover */
}

.modern-btn:active {
  transform: translateY(1px);
  background: #595959;  /* Back to solid black when clicked */
}

/* Styles for desktop (screens 768px and wider) */
@media (min-width: 768px) {
  .modern-btn {
    padding: 12px 24px;
    font-size: 16px;
    width: auto;
    display: inline-block;
  }
}

/* image in front of H1 */
.title-container {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 20px;
}

.profile-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #aaa7a7;
    transition: transform 0.3s ease;
}

.profile-image:hover {
    transform: scale(1.05);
}

/* Adjust for mobile screens */
@media (max-width: 768px) {
    .title-container {
        gap: 12px;
    }

    .profile-image {
        width: 65px;
        height: 65px;
        border-width: 2.1px;
    }
    
    .header .title {
        font-size: 1.75rem;
		line-height: 1.45;
    }
}

/* Adjust for very small screens */
@media (max-width: 480px) {
    .title-container {
        flex-direction: column;
        text-align: center;
    }

    .profile-image {
        margin-bottom: 10px;
    }
}




.card-actions{
  display:flex;
  gap:12px;
  justify-content:center;   /* centers the whole group */
  align-items:center;
  flex-wrap: wrap;           /* optional: wrap on small screens */
  margin: 50px 0 12px;       /* move vertical spacing here */
}

/* remove auto margins in flex context */
.card-actions .start-reading-btn{
  margin: 0;                 /* no auto margins */
  display: inline-flex;      /* nicer alignment in flex */
}

.card-actions .btn-ghost{
  margin: 0;
}


/* Start Reading Button */
.start-reading-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 250px;
}

.start-reading-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

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

/* Ghost (light) button — Ancient Egyptian vibe */
.btn-ghost {
  --gold: #c9a659;        /* papyrus-gold accent */
  --ink:  #3b2d15;        /* dark brown ink */
  --paper:#ffffff;        /* button fill (matches white bg) */
  --edge: #e6dcc6;        /* warm sand border */

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .5rem;

  padding: .7rem 1.25rem;
  border-radius: 999px;
  border: 1.5px solid var(--edge);
  background: var(--paper);

  color: #8b7355;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: .2px;

  /* Subtle emboss + warm inner glow */
  box-shadow:
    0 1px 0 rgba(0,0,0,.06),
    inset 0 0 0 1px #fff,
    inset 0 -6px 18px rgba(201,166,89,.12);

  text-shadow: 0 1px 0 rgba(255,255,255,.65);
  cursor: pointer;
  user-select: none;
  transition: border-color .2s ease, box-shadow .2s ease, transform .1s ease;
  min-width: 150px;
}

/* Hover: hint of gold + gentle lift */
.btn-ghost:hover {
  border-color: var(--gold);
  box-shadow:
    0 2px 6px rgba(0,0,0,.08),
    inset 0 0 0 1px #fff,
    inset 0 -8px 22px rgba(201,166,89,.18),
    0 0 0 3px rgba(201,166,89,.10);
  transform: translateY(-1px);
}

/* Active: press in */
.btn-ghost:active {
  transform: translateY(0);
  box-shadow:
    inset 0 2px 8px rgba(0,0,0,.12),
    inset 0 0 0 1px #fff;
}

/* Keyboard focus ring in gold */
.btn-ghost:focus-visible {
  outline: none;
  box-shadow:
    0 0 0 3px rgba(201,166,89,.35),
    0 1px 0 rgba(0,0,0,.06),
    inset 0 0 0 1px #fff;
}

/* Disabled state */
.btn-ghost:disabled {
  opacity: .6;
  cursor: not-allowed;
  transform: none;
}



















