*,
*::before,
*::after {
  box-sizing: border-box;
}
body {
  font-family: Arial, sans-serif;
  margin: 20px;
  background: #f5f5f5; 
}

.input-box {
    display: flex;
  flex-direction: column;
  gap: 12px;
  max-width: 600px;
  margin-bottom: 30px;
  

}

textarea {
  padding: 10px;
  font-size: 16px;
  resize: none;
}

select, button {
  padding: 10px;
  font-size: 16px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: 30px;
} 

.emotion-box {
  background-color: #fff;
  border-radius: 10px;
  padding: 15px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.1);
  min-height: 120px;
}

.thoughts {
  margin-top: 10px;
}

.thought {
  background-color: #e6f7ff;
  border-left: 4px solid #1890ff;
  padding: 8px;
  margin-bottom: 8px;
  border-radius: 4px;
}

.thought {
  background-color: #dcf8c6;
  padding: 10px 15px;
  border-radius: 20px;
  margin-bottom: 10px;
  position: relative;
  max-width: 90%;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  font-size: 14px;
  word-wrap: break-word;
}

.thought::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 15px;
  width: 0;
  height: 0;
  border: 10px solid transparent;
  border-top-color: #dcf8c6;
  border-bottom: 0;
  border-right: 0;
  margin-left: -5px;
  margin-bottom: -10px;
}

.like-btn {
  background: transparent;
  border: none;
  color: #e91e63;
  font-size: 14px;
  cursor: pointer;
  margin-top: 5px;
  padding: 0;
}
.form-row {
display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

#likeToggle {
  background-color: transparent;
  border: 1px solid #ccc;
  padding: 5px 12px;
  font-size: 16px;
  color: #e91e63;
  border-radius: 6px;
  cursor: pointer;
}

#likeToggle.liked {
  background-color: #ffe6ee;
  border-color: #e91e63;
}
/* Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Common bubble animation */
.thought {
  animation: fadeIn 0.4s ease;
}

textarea#thoughtInput {
  width: 100%;
  max-width: 100%;
  min-height: 100px;
  padding: 15px 20px;
  font-size: 16px;
  font-family: inherit;
  border: none;
  border-radius: 25px;
  background-color: var(--bubble-color, #dcf8c6); /* default green */
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  outline: none;
  resize: vertical;
  transition: background-color 0.2s ease;

}
textarea#thoughtInput::after {
    content: "";
  position: absolute;
  bottom: -10px;
  right: 20px;
  width: 0;
  height: 0;
  border: 10px solid transparent;
  border-top-color: var(--bubble-color, #dcf8c6);
  border-bottom: 0;
  border-left: 0;
  margin-right: -5px;

}

textarea#thoughtInput:focus {
  background-color: #fff;
  box-shadow: 0 0 0 3px rgba(100, 149, 237, 0.2);
}

button {
  font-size: 16px;
  padding: 10px 18px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  transition: background-color 0.2s ease-in-out;
}

button:hover {
  opacity: 0.9;
}

/* Submit button */
button[type="submit"], button:not(#likeToggle) {
  background-color: #4CAF50;
  color: white;
}

/* Like toggle button */
#likeToggle {
  background-color: #fff0f5;
  border: 1px solid #e91e63;
  color: #e91e63;
  font-weight: bold;
}

#likeToggle.liked {
  background-color: #e91e63;
  color: white;
}

.chat-bubble-input {
  position: relative;
  width: 100%;
  max-width: 100%;  /* stay inside container */
  overflow: hidden;
}

/* new */
body {
  font-family: Arial, sans-serif;
  background-color: #f9f9f9;
  margin: 0;
  padding: 0;
  display: flex;
  justify-content: center;
}

.app-container {
  width: 100%;
  max-width: 600px;
  padding: 20px;
  box-sizing: border-box;
  background: white;
  min-height: 100vh;
}

/* Title */
h2 {
  margin-bottom: 20px;
  font-size: 22px;
  text-align: center;
}

/* Form layout */
.input-box {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* Two-column grid */
.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: repeat(3, 1fr);
  gap: 12px;
  margin-top: 30px;
}

/* Emotion box styling */
.emotion-box {
  background-color: #ffffff;
  border-radius: 12px;
  padding: 10px 15px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
  min-height: 100px;
}

.emotion-box h3 {
  margin-top: 0;
  font-size: 16px;
}
/* Header Styles */
        header {
            background-color: #ffffff;
            box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
            padding: 0.75rem 1rem;
            display: flex;
            align-items: center;
            justify-content: space-between;
            border-bottom-left-radius: 0.5rem;
            border-bottom-right-radius: 0.5rem;
        }

        .header-left, .header-right {
            display: flex;
            align-items: center;
            gap: 0.5rem; /* Equivalent to space-x-2 or space-x-3 */
        }

        .hamburger-icon, .settings-icon {
            width: 1.5rem; /* w-6 */
            height: 1.5rem; /* h-6 */
            color: #4b5563; /* text-gray-700 */
            cursor: pointer;
        }

        .user-avatar {
            width: 2.5rem; /* w-10 */
            height: 2.5rem; /* h-10 */
            border-radius: 9999px; /* rounded-full */
            border: 2px solid #a78bfa; /* border-2 border-purple-400 */
        }
        #logo {
            margin-top: 1rem;
            margin-left: 4.5rem;
        }
        #title{
            display: flex;
            justify-content: space-around;
        }
.emotion-box{
    background-color: #D9D9D9;
}
.thought-bubble .meta {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: #555;
  margin-top: 5px;
}

.thought-bubble .name {
  font-style: italic;
}

.thought-bubble .timestamp {
  font-family: monospace;
  opacity: 0.7;
}
.thought-bubble.joy {
 background-color: #fff3cd; /* soft yellow */
}

.thought-bubble.curious {
  background-color: #d1ecf1;
}

.thought-bubble.amazed {
  background-color: #f8d7da;
}

.thought-bubble.inspired {
  background-color: #e2e3ff;
}

.thought-bubble.calm {
  background-color: #d4edda;
}

.thought-bubble.rebellious {
background-color: #fbe9e7;
}
.thought-bubble {
  padding: 12px 16px;
  margin-bottom: 10px;
  border-radius: 20px;
  position: relative;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
  color: #333;
  font-size: 16px;
  max-width: 90%;
  word-wrap: break-word;
}
#nameInput {
  width: 100%;
  max-width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #ccc;
  border-radius: 25px;
  font-size: 16px;
  outline: none;
  margin-bottom: 10px;
  box-sizing: border-box;
  background-color: #f9f9f9;
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

#nameInput:focus {
  border-color: #007aff; /* iOS-style blue */
  box-shadow: 0 0 4px rgba(0, 122, 255, 0.3);
  background-color: #fff;
}
.app-container {
  transition: background-color 0.3s, color 0.3s;
  font-family: sans-serif;
  padding: 1rem;
  border-radius: 1rem;
}

/* Light theme */
.app-container.light, header{
  background-color: #f2f2f2;
  color: #333;
}

/* Dark theme */
.app-container.dark, header{
  background-color: #121212;
  color: #f9f9f9;
}

/* Chat bubble styling */
.app-container .bubble {
  background-color: #fff;
  border: 1px solid #ccc;
  color: #000;
}

.app-container.dark .bubble {
  background-color: #1e1e1e;
  border-color: #444;
  color: #eee;
}

/* Toggle button */
.theme-toggle {
  padding: 0.5rem 1rem;
  border: none;
  background-color: #888;
  color: #fff;
  border-radius: 20px;
  cursor: pointer;
  font-weight: bold;
  z-index: 1000;
}

#arrow{
  text-decoration: none;
  font-size: 2.5rem;
  color: green;
  padding: 4rem 0 0 2rem;
}

.app-container.dark .emotion-box h3 {
  color: #000;
}







    
/* Responsive tweaks */
@media (max-width: 500px) {

  .grid {
  display: grid;
  /* grid-template-columns: 1fr 1fr; */
  grid-template-columns: repeat(2, 1fr);
  grid-auto-rows: repeat(3, 1fr);
  gap: 12px;
  margin-top: 30px;
}

  .form-row {
    flex-direction: column;
    align-items: stretch;
  }

  button, select {
    width: 100%;
  }
}
 

