/* 全体設定：基本の背景色、フォントなど */
body {
  margin: 0;
  font-family: 'Poppins', Arial, sans-serif; /* フォント設定 */
  background-color: #fff5f7; /* ページ全体の背景色 */
  color: #333; /* 基本テキスト色 */
  line-height: 1.6;
  display: flex;
  justify-content: center;
  padding: 20px;
}

/* コンテンツの中央に配置されるコンテナ */
.container {
  width: 100%;
  max-width: 720px;
  background: #fff; /* コンテナの背景色 */
  border-radius: 15px; /* 角を丸くする */
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); /* 軽い影の効果 */
  overflow: hidden;
  animation: fadeIn 1.2s ease-out; /* コンテナのアニメーション */
}

/* コンテナのフェードインアニメーション */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ヘッダー部分のデザイン */
.header {
  background: linear-gradient(45deg, #ff85b1, #ff4a75); /* ヘッダーのグラデーション背景 */
  color: #fff; /* ヘッダーテキストの色 */
  padding: 20px;
  text-align: center;
  font-size: 2rem;
  font-weight: bold;
}

/* 画像の設定 */
.image-wrapper img {
  width: 100%;
  height: auto;
  display: block;
  border-bottom: 5px solid #ffe1e8; /* 画像下部のボーダー色 */
}
.image-wrapper {
  max-width: 100%; /* 親要素が広がりすぎるのを防ぐ */
  overflow: hidden; /* はみ出し防止 */
}
.image-wrapper {
  max-width: 100%; /* 親要素がはみ出さないようにする */
  width: 100%; /* 画面幅いっぱいに広がる */
  overflow: hidden; /* はみ出し防止 */
  display: flex;
  justify-content: center;
}
.image-wrapper img {
  max-width: 100%; /* 画像が親要素より大きくならないようにする */
  height: auto;
  display: block;
}
/* コンテンツ内の段落 */
.content {
  padding: 20px;
}

.content p {
  font-size: 1rem;
  color: #555; /* メインコンテンツ内のテキスト色 */
  text-align: center;
  margin-bottom: 20px;
}

/* 音声プレーヤーの設定 */
audio {
  width: 100%;
  margin-top: 20px;
  border-radius: 5px;
  outline: none;
}

/* ペット情報テーブル */
.pet-info-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 20px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); /* 軽い影 */
}

/* テーブルヘッダーの設定 */
.pet-info-table th {
  background-color: #ffd5e0; /* テーブルヘッダーの背景色 */
  color: #ff4a75; /* テーブルヘッダーのテキスト色 */
  text-align: center;
  font-weight: bold;
}

/* テーブルデータの背景色 */
.pet-info-table td {
  background-color: #fff;
}

/* ✅ 重要修正部分：英数字・URL・メールアドレスをスマホで折り返す設定 */
.pet-info-table th,
.pet-info-table td {
  word-break: break-all;         /* 単語途中でも折り返す */
  word-wrap: break-word;         /* 古いブラウザ対応 */
  overflow-wrap: anywhere;       /* 最新ブラウザ対応 */
  white-space: normal;           /* 改行を許可 */
  max-width: 100%;               /* 幅を超えないよう制限 */
  overflow: hidden;              /* 万一のはみ出し防止 */
}

/* 偶数行の背景色 */
.pet-info-table tr:nth-child(even) td {
  background-color: #fdf7f9; /* 偶数行の背景色 */
}

/* ログインボタン（index.htmlに表示するボタン） */
.login-button {
  display: flex;
  justify-content: center;
  margin: 20px 0;
}

.login-button button {
  background-color: #ff85b1; /* ボタンの背景色 */
  color: white; /* ボタンのテキスト色 */
  border: none;
  padding: 10px 20px;
  font-size: 1rem;
  border-radius: 25px; /* 軽い丸み */
  cursor: pointer;
  transition: background-color 0.3s ease;
}

.login-button button:hover {
  background-color: #ff4a75; /* ホバー時の色 */
}

/* ログイン画面専用のボタン（login.html に適用） */
.login-form .login-button button {
  width: auto;
  max-width: 200px; /* 横幅の制限 */
  border-radius: 50px; /* かわいらしい丸み */
  box-shadow: 0 3px 6px rgba(0, 0, 0, 0.1); /* 軽い影 */
}

/* ログインフォームの設定 */
.login-form {
  display: flex;
  flex-direction: column;
  gap: 15px;
  padding: 20px;
}

/* ラベルの設定 */
.form-group label {
  font-size: 1rem;
  color: #333; /* ラベルのテキスト色 */
}

/* 入力フィールドの設定 */
.form-group input {
  width: 100%;
  padding: 10px;
  border-radius: 5px;
  border: 1px solid #ddd; /* 入力フィールドのボーダー色 */
}

/* パスワードリンク */
.forgot-password {
  text-align: center;
  margin-top: 15px;
}

.forgot-password a {
  color: #ff4a75; /* パスワードリンクのテキスト色 */
  text-decoration: none;
}

.forgot-password a:hover {
  text-decoration: underline;
}
.edit-link {
  display: inline-block;
  padding: 10px 20px;
  background-color: #ff85b1;
  color: white;
  text-decoration: none;
  border-radius: 25px;
  font-size: 1rem;
  text-align: center;
  transition: background-color 0.3s ease;
}

.edit-link:hover {
  background-color: #ff4a75;
}


/* パスワード変更リンクのデザイン */
.change-password {
  text-align: center;
  margin-top: 10px;
}

.change-password a {
  color: #ff4a75; /* パスワード変更リンクの色 */
  text-decoration: none;
}

.change-password a:hover {
  text-decoration: underline;
}
body {
  font-family: 'Poppins', Arial, sans-serif;
  background-color: #fff5f7;
  color: #333;
  display: flex;
  justify-content: center;
  padding: 20px;
}

.container {
  max-width: 720px;
  background: white;
  border-radius: 10px;
  padding: 20px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.header {
  font-size: 24px;
  text-align: center;
  color: white;
  background: linear-gradient(45deg, #ff85b1, #ff4a75);
  padding: 15px;
  border-radius: 10px 10px 0 0;
}

.image-wrapper img {
  max-width: 100%;
  height: auto;
  border: 2px solid #ff85b1;
}

.edit-table, .pet-info-table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 15px;
}

.edit-table th, .pet-info-table th {
  background-color: #ffd5e0;
  padding: 10px;
  text-align: left;
}

.edit-table td, .pet-info-table td {
  padding: 10px;
  border: 1px solid #ff85b1;
}

/* ✅ edit-tableにも同様のテキスト折り返しを適用 */
.edit-table th,
.edit-table td {
  word-break: break-all;
  overflow-wrap: anywhere;
  white-space: normal;
  max-width: 100%;
  overflow: hidden;
}

.form-group {
  margin-bottom: 20px;
}

button {
  background-color: #ff85b1;
  color: white;
  border: none;
  padding: 10px 20px;
  border-radius: 20px;
  cursor: pointer;
}

button:hover {
  background-color: #ff4a75;
}


/* フッター部分の設定 */
.footer {
  text-align: center;
  font-size: 0.9rem;
  color: #888; /* フッターのテキスト色 */
  padding: 10px 0;
  background-color: #fff5f7; /* フッターの背景色 */
  border-top: 2px solid #ffe1e8; /* フッターの上部ボーダー色 */
}

/* 小さな画面用のレスポンシブ設定 */
@media (max-width: 768px) {
  .header {
    font-size: 1.5rem;
    padding: 15px;
  }

  .content p {
    font-size: 0.9rem;
  }

  .pet-info-table th, 
  .pet-info-table td {
    font-size: 0.9rem;
  }

  .login-form .login-button button {
    max-width: 100%; /* 小さな画面ではボタン幅を広げる */
  }
}
